diff --git a/contracts-abi/abi/PreConfCommitmentStore.abi b/contracts-abi/abi/PreConfCommitmentStore.abi index a6a49c9ec..48dff1852 100644 --- a/contracts-abi/abi/PreConfCommitmentStore.abi +++ b/contracts-abi/abi/PreConfCommitmentStore.abi @@ -204,6 +204,11 @@ "type": "string", "internalType": "string" }, + { + "name": "revertingTxHashes", + "type": "string", + "internalType": "string" + }, { "name": "commitmentHash", "type": "bytes32", @@ -299,6 +304,11 @@ "type": "string", "internalType": "string" }, + { + "name": "_revertingTxHashes", + "type": "string", + "internalType": "string" + }, { "name": "_bid", "type": "uint256", @@ -390,6 +400,11 @@ "type": "string", "internalType": "string" }, + { + "name": "revertingTxHashes", + "type": "string", + "internalType": "string" + }, { "name": "commitmentHash", "type": "bytes32", @@ -474,6 +489,11 @@ "type": "string", "internalType": "string" }, + { + "name": "revertingTxHashes", + "type": "string", + "internalType": "string" + }, { "name": "commitmentHash", "type": "bytes32", @@ -612,6 +632,11 @@ "type": "string", "internalType": "string" }, + { + "name": "_revertingTxHashes", + "type": "string", + "internalType": "string" + }, { "name": "_bid", "type": "uint256", @@ -792,6 +817,11 @@ "type": "string", "internalType": "string" }, + { + "name": "revertingTxHashes", + "type": "string", + "internalType": "string" + }, { "name": "decayStartTimeStamp", "type": "uint64", @@ -1027,6 +1057,11 @@ "type": "string", "internalType": "string" }, + { + "name": "revertingTxHashes", + "type": "string", + "internalType": "string" + }, { "name": "bidSignature", "type": "bytes", @@ -1052,49 +1087,61 @@ "name": "verifyPreConfCommitment", "inputs": [ { - "name": "txnHash", - "type": "string", - "internalType": "string" - }, - { - "name": "bid", - "type": "uint256", - "internalType": "uint256" - }, - { - "name": "blockNumber", - "type": "uint64", - "internalType": "uint64" - }, - { - "name": "decayStartTimeStamp", - "type": "uint64", - "internalType": "uint64" - }, - { - "name": "decayEndTimeStamp", - "type": "uint64", - "internalType": "uint64" - }, - { - "name": "bidHash", - "type": "bytes32", - "internalType": "bytes32" - }, - { - "name": "bidSignature", - "type": "bytes", - "internalType": "bytes" - }, - { - "name": "commitmentSignature", - "type": "bytes", - "internalType": "bytes" - }, - { - "name": "sharedSecretKey", - "type": "bytes", - "internalType": "bytes" + "name": "params", + "type": "tuple", + "internalType": "struct PreConfCommitmentStore.CommitmentParams", + "components": [ + { + "name": "txnHash", + "type": "string", + "internalType": "string" + }, + { + "name": "revertingTxHashes", + "type": "string", + "internalType": "string" + }, + { + "name": "bid", + "type": "uint256", + "internalType": "uint256" + }, + { + "name": "blockNumber", + "type": "uint64", + "internalType": "uint64" + }, + { + "name": "decayStartTimeStamp", + "type": "uint64", + "internalType": "uint64" + }, + { + "name": "decayEndTimeStamp", + "type": "uint64", + "internalType": "uint64" + }, + { + "name": "bidHash", + "type": "bytes32", + "internalType": "bytes32" + }, + { + "name": "bidSignature", + "type": "bytes", + "internalType": "bytes" + }, + { + "name": "commitmentSignature", + "type": "bytes", + "internalType": "bytes" + }, + { + "name": "sharedSecretKey", + "type": "bytes", + "internalType": "bytes" + } + ] } ], "outputs": [ @@ -1169,6 +1216,12 @@ "indexed": false, "internalType": "string" }, + { + "name": "revertingTxHashes", + "type": "string", + "indexed": false, + "internalType": "string" + }, { "name": "commitmentHash", "type": "bytes32", @@ -1287,6 +1340,12 @@ "indexed": false, "internalType": "string" }, + { + "name": "revertingTxHashes", + "type": "string", + "indexed": false, + "internalType": "string" + }, { "name": "bid", "type": "uint256", diff --git a/contracts-abi/clients/PreConfCommitmentStore/PreConfCommitmentStore.go b/contracts-abi/clients/PreConfCommitmentStore/PreConfCommitmentStore.go index 2e5622eaf..49d325bca 100644 --- a/contracts-abi/clients/PreConfCommitmentStore/PreConfCommitmentStore.go +++ b/contracts-abi/clients/PreConfCommitmentStore/PreConfCommitmentStore.go @@ -29,6 +29,20 @@ var ( _ = abi.ConvertType ) +// PreConfCommitmentStoreCommitmentParams is an auto generated low-level Go binding around an user-defined struct. +type PreConfCommitmentStoreCommitmentParams struct { + TxnHash string + RevertingTxHashes string + Bid *big.Int + BlockNumber uint64 + DecayStartTimeStamp uint64 + DecayEndTimeStamp uint64 + BidHash [32]byte + BidSignature []byte + CommitmentSignature []byte + SharedSecretKey []byte +} + // PreConfCommitmentStoreEncrPreConfCommitment is an auto generated low-level Go binding around an user-defined struct. type PreConfCommitmentStoreEncrPreConfCommitment struct { IsUsed bool @@ -49,6 +63,7 @@ type PreConfCommitmentStorePreConfCommitment struct { DecayStartTimeStamp uint64 DecayEndTimeStamp uint64 TxnHash string + RevertingTxHashes string CommitmentHash [32]byte BidSignature []byte CommitmentSignature []byte @@ -58,7 +73,7 @@ type PreConfCommitmentStorePreConfCommitment struct { // PreconfcommitmentstoreMetaData contains all meta data concerning the Preconfcommitmentstore contract. var PreconfcommitmentstoreMetaData = &bind.MetaData{ - ABI: "[{\"type\":\"constructor\",\"inputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"fallback\",\"stateMutability\":\"payable\"},{\"type\":\"receive\",\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"DOMAIN_SEPARATOR_BID\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"DOMAIN_SEPARATOR_PRECONF\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"EIP712_BID_TYPEHASH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"EIP712_COMMITMENT_TYPEHASH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"UPGRADE_INTERFACE_VERSION\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"string\",\"internalType\":\"string\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"_bytesToHexString\",\"inputs\":[{\"name\":\"_bytes\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[{\"name\":\"\",\"type\":\"string\",\"internalType\":\"string\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"bidderRegistry\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIBidderRegistry\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"blockTracker\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIBlockTracker\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"blocksPerWindow\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"commitmentDispatchWindow\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"commitments\",\"inputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"bidder\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"bidHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"commitmentHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"commitmentsCount\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"encryptedCommitments\",\"inputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commitmentDigest\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getBidHash\",\"inputs\":[{\"name\":\"_txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"_bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCommitment\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structPreConfCommitmentStore.PreConfCommitment\",\"components\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"bidder\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"bidHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"commitmentHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCommitmentIndex\",\"inputs\":[{\"name\":\"commitment\",\"type\":\"tuple\",\"internalType\":\"structPreConfCommitmentStore.PreConfCommitment\",\"components\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"bidder\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"bidHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"commitmentHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"getEncryptedCommitment\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structPreConfCommitmentStore.EncrPreConfCommitment\",\"components\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commitmentDigest\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getEncryptedCommitmentIndex\",\"inputs\":[{\"name\":\"commitment\",\"type\":\"tuple\",\"internalType\":\"structPreConfCommitmentStore.EncrPreConfCommitment\",\"components\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commitmentDigest\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"getPreConfHash\",\"inputs\":[{\"name\":\"_txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"_bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_bidHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"_bidSignature\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"_sharedSecretKey\",\"type\":\"string\",\"internalType\":\"string\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getTxnHashFromCommitment\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"initialize\",\"inputs\":[{\"name\":\"_providerRegistry\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_bidderRegistry\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_oracle\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_owner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_blockTracker\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_commitmentDispatchWindow\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_blocksPerWindow\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"initiateReward\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"residualBidPercentAfterDecay\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"initiateSlash\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"residualBidPercentAfterDecay\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"lastProcessedBlock\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"openCommitment\",\"inputs\":[{\"name\":\"encryptedCommitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"oracle\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"owner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"providerRegistry\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIProviderRegistry\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"proxiableUUID\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"renounceOwnership\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"storeEncryptedCommitment\",\"inputs\":[{\"name\":\"commitmentDigest\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"outputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"transferOwnership\",\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"updateBidderRegistry\",\"inputs\":[{\"name\":\"newBidderRegistry\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"updateCommitmentDispatchWindow\",\"inputs\":[{\"name\":\"newDispatchWindow\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"updateOracle\",\"inputs\":[{\"name\":\"newOracle\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"updateProviderRegistry\",\"inputs\":[{\"name\":\"newProviderRegistry\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"upgradeToAndCall\",\"inputs\":[{\"name\":\"newImplementation\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"data\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[],\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"verifyBid\",\"inputs\":[{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[{\"name\":\"messageDigest\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"recoveredAddress\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"verifyPreConfCommitment\",\"inputs\":[{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"bidHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[{\"name\":\"preConfHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"commiterAddress\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"event\",\"name\":\"CommitmentStored\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"bidder\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"commiter\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"bid\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"bidHash\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"},{\"name\":\"commitmentHash\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"EncryptedCommitmentStored\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"commiter\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"commitmentDigest\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Initialized\",\"inputs\":[{\"name\":\"version\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"inputs\":[{\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"SignatureVerified\",\"inputs\":[{\"name\":\"signer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"txnHash\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"},{\"name\":\"bid\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Upgraded\",\"inputs\":[{\"name\":\"implementation\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"error\",\"name\":\"AddressEmptyCode\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"ERC1967InvalidImplementation\",\"inputs\":[{\"name\":\"implementation\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"ERC1967NonPayable\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"FailedInnerCall\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidInitialization\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"NotInitializing\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"OwnableInvalidOwner\",\"inputs\":[{\"name\":\"owner\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"OwnableUnauthorizedAccount\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"UUPSUnauthorizedCallContext\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"UUPSUnsupportedProxiableUUID\",\"inputs\":[{\"name\":\"slot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]}]", + ABI: "[{\"type\":\"constructor\",\"inputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"fallback\",\"stateMutability\":\"payable\"},{\"type\":\"receive\",\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"DOMAIN_SEPARATOR_BID\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"DOMAIN_SEPARATOR_PRECONF\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"EIP712_BID_TYPEHASH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"EIP712_COMMITMENT_TYPEHASH\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"UPGRADE_INTERFACE_VERSION\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"string\",\"internalType\":\"string\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"_bytesToHexString\",\"inputs\":[{\"name\":\"_bytes\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[{\"name\":\"\",\"type\":\"string\",\"internalType\":\"string\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"bidderRegistry\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIBidderRegistry\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"blockTracker\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIBlockTracker\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"blocksPerWindow\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"commitmentDispatchWindow\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"commitments\",\"inputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"bidder\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"bidHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"revertingTxHashes\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"commitmentHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"commitmentsCount\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"encryptedCommitments\",\"inputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commitmentDigest\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getBidHash\",\"inputs\":[{\"name\":\"_txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"_revertingTxHashes\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"_bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCommitment\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structPreConfCommitmentStore.PreConfCommitment\",\"components\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"bidder\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"bidHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"revertingTxHashes\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"commitmentHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getCommitmentIndex\",\"inputs\":[{\"name\":\"commitment\",\"type\":\"tuple\",\"internalType\":\"structPreConfCommitmentStore.PreConfCommitment\",\"components\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"bidder\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"bidHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"revertingTxHashes\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"commitmentHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"getEncryptedCommitment\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structPreConfCommitmentStore.EncrPreConfCommitment\",\"components\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commitmentDigest\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getEncryptedCommitmentIndex\",\"inputs\":[{\"name\":\"commitment\",\"type\":\"tuple\",\"internalType\":\"structPreConfCommitmentStore.EncrPreConfCommitment\",\"components\":[{\"name\":\"isUsed\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"commiter\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"commitmentDigest\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"}]}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"getPreConfHash\",\"inputs\":[{\"name\":\"_txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"_revertingTxHashes\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"_bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_bidHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"_bidSignature\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"_sharedSecretKey\",\"type\":\"string\",\"internalType\":\"string\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getTxnHashFromCommitment\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"initialize\",\"inputs\":[{\"name\":\"_providerRegistry\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_bidderRegistry\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_oracle\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_owner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_blockTracker\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_commitmentDispatchWindow\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"_blocksPerWindow\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"initiateReward\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"residualBidPercentAfterDecay\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"initiateSlash\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"residualBidPercentAfterDecay\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"lastProcessedBlock\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"openCommitment\",\"inputs\":[{\"name\":\"encryptedCommitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"revertingTxHashes\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"oracle\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"owner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"providerRegistry\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIProviderRegistry\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"proxiableUUID\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"renounceOwnership\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"storeEncryptedCommitment\",\"inputs\":[{\"name\":\"commitmentDigest\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"outputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"transferOwnership\",\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"updateBidderRegistry\",\"inputs\":[{\"name\":\"newBidderRegistry\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"updateCommitmentDispatchWindow\",\"inputs\":[{\"name\":\"newDispatchWindow\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"updateOracle\",\"inputs\":[{\"name\":\"newOracle\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"updateProviderRegistry\",\"inputs\":[{\"name\":\"newProviderRegistry\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"upgradeToAndCall\",\"inputs\":[{\"name\":\"newImplementation\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"data\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[],\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"verifyBid\",\"inputs\":[{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"revertingTxHashes\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[{\"name\":\"messageDigest\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"recoveredAddress\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"verifyPreConfCommitment\",\"inputs\":[{\"name\":\"params\",\"type\":\"tuple\",\"internalType\":\"structPreConfCommitmentStore.CommitmentParams\",\"components\":[{\"name\":\"txnHash\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"revertingTxHashes\",\"type\":\"string\",\"internalType\":\"string\"},{\"name\":\"bid\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"bidHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}]}],\"outputs\":[{\"name\":\"preConfHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"commiterAddress\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"event\",\"name\":\"CommitmentStored\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"bidder\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"commiter\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"bid\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"bidHash\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"decayStartTimeStamp\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"decayEndTimeStamp\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"txnHash\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"},{\"name\":\"revertingTxHashes\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"},{\"name\":\"commitmentHash\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"bidSignature\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"sharedSecretKey\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"EncryptedCommitmentStored\",\"inputs\":[{\"name\":\"commitmentIndex\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"commiter\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"commitmentDigest\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"},{\"name\":\"commitmentSignature\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"},{\"name\":\"dispatchTimestamp\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Initialized\",\"inputs\":[{\"name\":\"version\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"inputs\":[{\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"SignatureVerified\",\"inputs\":[{\"name\":\"signer\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"txnHash\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"},{\"name\":\"revertingTxHashes\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"},{\"name\":\"bid\",\"type\":\"uint256\",\"indexed\":true,\"internalType\":\"uint256\"},{\"name\":\"blockNumber\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Upgraded\",\"inputs\":[{\"name\":\"implementation\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"error\",\"name\":\"AddressEmptyCode\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"ERC1967InvalidImplementation\",\"inputs\":[{\"name\":\"implementation\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"ERC1967NonPayable\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"FailedInnerCall\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidInitialization\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"NotInitializing\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"OwnableInvalidOwner\",\"inputs\":[{\"name\":\"owner\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"OwnableUnauthorizedAccount\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"UUPSUnauthorizedCallContext\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"UUPSUnsupportedProxiableUUID\",\"inputs\":[{\"name\":\"slot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]}]", } // PreconfcommitmentstoreABI is the input ABI used to generate the binding from. @@ -519,7 +534,7 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) CommitmentDi // Commitments is a free data retrieval call binding the contract method 0x839df945. // -// Solidity: function commitments(bytes32 ) view returns(bool isUsed, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) +// Solidity: function commitments(bytes32 ) view returns(bool isUsed, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, string revertingTxHashes, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) Commitments(opts *bind.CallOpts, arg0 [32]byte) (struct { IsUsed bool Bidder common.Address @@ -530,6 +545,7 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) Commitments(opts *b DecayStartTimeStamp uint64 DecayEndTimeStamp uint64 TxnHash string + RevertingTxHashes string CommitmentHash [32]byte BidSignature []byte CommitmentSignature []byte @@ -549,6 +565,7 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) Commitments(opts *b DecayStartTimeStamp uint64 DecayEndTimeStamp uint64 TxnHash string + RevertingTxHashes string CommitmentHash [32]byte BidSignature []byte CommitmentSignature []byte @@ -568,11 +585,12 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) Commitments(opts *b outstruct.DecayStartTimeStamp = *abi.ConvertType(out[6], new(uint64)).(*uint64) outstruct.DecayEndTimeStamp = *abi.ConvertType(out[7], new(uint64)).(*uint64) outstruct.TxnHash = *abi.ConvertType(out[8], new(string)).(*string) - outstruct.CommitmentHash = *abi.ConvertType(out[9], new([32]byte)).(*[32]byte) - outstruct.BidSignature = *abi.ConvertType(out[10], new([]byte)).(*[]byte) - outstruct.CommitmentSignature = *abi.ConvertType(out[11], new([]byte)).(*[]byte) - outstruct.DispatchTimestamp = *abi.ConvertType(out[12], new(uint64)).(*uint64) - outstruct.SharedSecretKey = *abi.ConvertType(out[13], new([]byte)).(*[]byte) + outstruct.RevertingTxHashes = *abi.ConvertType(out[9], new(string)).(*string) + outstruct.CommitmentHash = *abi.ConvertType(out[10], new([32]byte)).(*[32]byte) + outstruct.BidSignature = *abi.ConvertType(out[11], new([]byte)).(*[]byte) + outstruct.CommitmentSignature = *abi.ConvertType(out[12], new([]byte)).(*[]byte) + outstruct.DispatchTimestamp = *abi.ConvertType(out[13], new(uint64)).(*uint64) + outstruct.SharedSecretKey = *abi.ConvertType(out[14], new([]byte)).(*[]byte) return *outstruct, err @@ -580,7 +598,7 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) Commitments(opts *b // Commitments is a free data retrieval call binding the contract method 0x839df945. // -// Solidity: function commitments(bytes32 ) view returns(bool isUsed, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) +// Solidity: function commitments(bytes32 ) view returns(bool isUsed, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, string revertingTxHashes, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) Commitments(arg0 [32]byte) (struct { IsUsed bool Bidder common.Address @@ -591,6 +609,7 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) Commitments(arg0 [ DecayStartTimeStamp uint64 DecayEndTimeStamp uint64 TxnHash string + RevertingTxHashes string CommitmentHash [32]byte BidSignature []byte CommitmentSignature []byte @@ -602,7 +621,7 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) Commitments(arg0 [ // Commitments is a free data retrieval call binding the contract method 0x839df945. // -// Solidity: function commitments(bytes32 ) view returns(bool isUsed, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) +// Solidity: function commitments(bytes32 ) view returns(bool isUsed, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, string revertingTxHashes, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) Commitments(arg0 [32]byte) (struct { IsUsed bool Bidder common.Address @@ -613,6 +632,7 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) Commitments( DecayStartTimeStamp uint64 DecayEndTimeStamp uint64 TxnHash string + RevertingTxHashes string CommitmentHash [32]byte BidSignature []byte CommitmentSignature []byte @@ -713,12 +733,12 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) EncryptedCom return _Preconfcommitmentstore.Contract.EncryptedCommitments(&_Preconfcommitmentstore.CallOpts, arg0) } -// GetBidHash is a free data retrieval call binding the contract method 0x4e26887a. +// GetBidHash is a free data retrieval call binding the contract method 0xdbd007ab. // -// Solidity: function getBidHash(string _txnHash, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp) view returns(bytes32) -func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) GetBidHash(opts *bind.CallOpts, _txnHash string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64) ([32]byte, error) { +// Solidity: function getBidHash(string _txnHash, string _revertingTxHashes, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp) view returns(bytes32) +func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) GetBidHash(opts *bind.CallOpts, _txnHash string, _revertingTxHashes string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64) ([32]byte, error) { var out []interface{} - err := _Preconfcommitmentstore.contract.Call(opts, &out, "getBidHash", _txnHash, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp) + err := _Preconfcommitmentstore.contract.Call(opts, &out, "getBidHash", _txnHash, _revertingTxHashes, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp) if err != nil { return *new([32]byte), err @@ -730,23 +750,23 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) GetBidHash(opts *bi } -// GetBidHash is a free data retrieval call binding the contract method 0x4e26887a. +// GetBidHash is a free data retrieval call binding the contract method 0xdbd007ab. // -// Solidity: function getBidHash(string _txnHash, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp) view returns(bytes32) -func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) GetBidHash(_txnHash string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64) ([32]byte, error) { - return _Preconfcommitmentstore.Contract.GetBidHash(&_Preconfcommitmentstore.CallOpts, _txnHash, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp) +// Solidity: function getBidHash(string _txnHash, string _revertingTxHashes, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp) view returns(bytes32) +func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) GetBidHash(_txnHash string, _revertingTxHashes string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64) ([32]byte, error) { + return _Preconfcommitmentstore.Contract.GetBidHash(&_Preconfcommitmentstore.CallOpts, _txnHash, _revertingTxHashes, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp) } -// GetBidHash is a free data retrieval call binding the contract method 0x4e26887a. +// GetBidHash is a free data retrieval call binding the contract method 0xdbd007ab. // -// Solidity: function getBidHash(string _txnHash, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp) view returns(bytes32) -func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) GetBidHash(_txnHash string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64) ([32]byte, error) { - return _Preconfcommitmentstore.Contract.GetBidHash(&_Preconfcommitmentstore.CallOpts, _txnHash, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp) +// Solidity: function getBidHash(string _txnHash, string _revertingTxHashes, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp) view returns(bytes32) +func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) GetBidHash(_txnHash string, _revertingTxHashes string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64) ([32]byte, error) { + return _Preconfcommitmentstore.Contract.GetBidHash(&_Preconfcommitmentstore.CallOpts, _txnHash, _revertingTxHashes, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp) } // GetCommitment is a free data retrieval call binding the contract method 0x7795820c. // -// Solidity: function getCommitment(bytes32 commitmentIndex) view returns((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,bytes32,bytes,bytes,uint64,bytes)) +// Solidity: function getCommitment(bytes32 commitmentIndex) view returns((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,string,bytes32,bytes,bytes,uint64,bytes)) func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) GetCommitment(opts *bind.CallOpts, commitmentIndex [32]byte) (PreConfCommitmentStorePreConfCommitment, error) { var out []interface{} err := _Preconfcommitmentstore.contract.Call(opts, &out, "getCommitment", commitmentIndex) @@ -763,21 +783,21 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) GetCommitment(opts // GetCommitment is a free data retrieval call binding the contract method 0x7795820c. // -// Solidity: function getCommitment(bytes32 commitmentIndex) view returns((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,bytes32,bytes,bytes,uint64,bytes)) +// Solidity: function getCommitment(bytes32 commitmentIndex) view returns((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,string,bytes32,bytes,bytes,uint64,bytes)) func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) GetCommitment(commitmentIndex [32]byte) (PreConfCommitmentStorePreConfCommitment, error) { return _Preconfcommitmentstore.Contract.GetCommitment(&_Preconfcommitmentstore.CallOpts, commitmentIndex) } // GetCommitment is a free data retrieval call binding the contract method 0x7795820c. // -// Solidity: function getCommitment(bytes32 commitmentIndex) view returns((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,bytes32,bytes,bytes,uint64,bytes)) +// Solidity: function getCommitment(bytes32 commitmentIndex) view returns((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,string,bytes32,bytes,bytes,uint64,bytes)) func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) GetCommitment(commitmentIndex [32]byte) (PreConfCommitmentStorePreConfCommitment, error) { return _Preconfcommitmentstore.Contract.GetCommitment(&_Preconfcommitmentstore.CallOpts, commitmentIndex) } -// GetCommitmentIndex is a free data retrieval call binding the contract method 0x32528fb5. +// GetCommitmentIndex is a free data retrieval call binding the contract method 0x67e35d04. // -// Solidity: function getCommitmentIndex((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,bytes32,bytes,bytes,uint64,bytes) commitment) pure returns(bytes32) +// Solidity: function getCommitmentIndex((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,string,bytes32,bytes,bytes,uint64,bytes) commitment) pure returns(bytes32) func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) GetCommitmentIndex(opts *bind.CallOpts, commitment PreConfCommitmentStorePreConfCommitment) ([32]byte, error) { var out []interface{} err := _Preconfcommitmentstore.contract.Call(opts, &out, "getCommitmentIndex", commitment) @@ -792,16 +812,16 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) GetCommitmentIndex( } -// GetCommitmentIndex is a free data retrieval call binding the contract method 0x32528fb5. +// GetCommitmentIndex is a free data retrieval call binding the contract method 0x67e35d04. // -// Solidity: function getCommitmentIndex((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,bytes32,bytes,bytes,uint64,bytes) commitment) pure returns(bytes32) +// Solidity: function getCommitmentIndex((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,string,bytes32,bytes,bytes,uint64,bytes) commitment) pure returns(bytes32) func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) GetCommitmentIndex(commitment PreConfCommitmentStorePreConfCommitment) ([32]byte, error) { return _Preconfcommitmentstore.Contract.GetCommitmentIndex(&_Preconfcommitmentstore.CallOpts, commitment) } -// GetCommitmentIndex is a free data retrieval call binding the contract method 0x32528fb5. +// GetCommitmentIndex is a free data retrieval call binding the contract method 0x67e35d04. // -// Solidity: function getCommitmentIndex((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,bytes32,bytes,bytes,uint64,bytes) commitment) pure returns(bytes32) +// Solidity: function getCommitmentIndex((bool,address,address,uint256,uint64,bytes32,uint64,uint64,string,string,bytes32,bytes,bytes,uint64,bytes) commitment) pure returns(bytes32) func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) GetCommitmentIndex(commitment PreConfCommitmentStorePreConfCommitment) ([32]byte, error) { return _Preconfcommitmentstore.Contract.GetCommitmentIndex(&_Preconfcommitmentstore.CallOpts, commitment) } @@ -868,12 +888,12 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) GetEncrypted return _Preconfcommitmentstore.Contract.GetEncryptedCommitmentIndex(&_Preconfcommitmentstore.CallOpts, commitment) } -// GetPreConfHash is a free data retrieval call binding the contract method 0xd6d5ddc7. +// GetPreConfHash is a free data retrieval call binding the contract method 0xd3dff2ae. // -// Solidity: function getPreConfHash(string _txnHash, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp, bytes32 _bidHash, string _bidSignature, string _sharedSecretKey) view returns(bytes32) -func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) GetPreConfHash(opts *bind.CallOpts, _txnHash string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64, _bidHash [32]byte, _bidSignature string, _sharedSecretKey string) ([32]byte, error) { +// Solidity: function getPreConfHash(string _txnHash, string _revertingTxHashes, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp, bytes32 _bidHash, string _bidSignature, string _sharedSecretKey) view returns(bytes32) +func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) GetPreConfHash(opts *bind.CallOpts, _txnHash string, _revertingTxHashes string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64, _bidHash [32]byte, _bidSignature string, _sharedSecretKey string) ([32]byte, error) { var out []interface{} - err := _Preconfcommitmentstore.contract.Call(opts, &out, "getPreConfHash", _txnHash, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp, _bidHash, _bidSignature, _sharedSecretKey) + err := _Preconfcommitmentstore.contract.Call(opts, &out, "getPreConfHash", _txnHash, _revertingTxHashes, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp, _bidHash, _bidSignature, _sharedSecretKey) if err != nil { return *new([32]byte), err @@ -885,18 +905,18 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) GetPreConfHash(opts } -// GetPreConfHash is a free data retrieval call binding the contract method 0xd6d5ddc7. +// GetPreConfHash is a free data retrieval call binding the contract method 0xd3dff2ae. // -// Solidity: function getPreConfHash(string _txnHash, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp, bytes32 _bidHash, string _bidSignature, string _sharedSecretKey) view returns(bytes32) -func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) GetPreConfHash(_txnHash string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64, _bidHash [32]byte, _bidSignature string, _sharedSecretKey string) ([32]byte, error) { - return _Preconfcommitmentstore.Contract.GetPreConfHash(&_Preconfcommitmentstore.CallOpts, _txnHash, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp, _bidHash, _bidSignature, _sharedSecretKey) +// Solidity: function getPreConfHash(string _txnHash, string _revertingTxHashes, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp, bytes32 _bidHash, string _bidSignature, string _sharedSecretKey) view returns(bytes32) +func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) GetPreConfHash(_txnHash string, _revertingTxHashes string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64, _bidHash [32]byte, _bidSignature string, _sharedSecretKey string) ([32]byte, error) { + return _Preconfcommitmentstore.Contract.GetPreConfHash(&_Preconfcommitmentstore.CallOpts, _txnHash, _revertingTxHashes, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp, _bidHash, _bidSignature, _sharedSecretKey) } -// GetPreConfHash is a free data retrieval call binding the contract method 0xd6d5ddc7. +// GetPreConfHash is a free data retrieval call binding the contract method 0xd3dff2ae. // -// Solidity: function getPreConfHash(string _txnHash, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp, bytes32 _bidHash, string _bidSignature, string _sharedSecretKey) view returns(bytes32) -func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) GetPreConfHash(_txnHash string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64, _bidHash [32]byte, _bidSignature string, _sharedSecretKey string) ([32]byte, error) { - return _Preconfcommitmentstore.Contract.GetPreConfHash(&_Preconfcommitmentstore.CallOpts, _txnHash, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp, _bidHash, _bidSignature, _sharedSecretKey) +// Solidity: function getPreConfHash(string _txnHash, string _revertingTxHashes, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, uint64 _decayEndTimeStamp, bytes32 _bidHash, string _bidSignature, string _sharedSecretKey) view returns(bytes32) +func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) GetPreConfHash(_txnHash string, _revertingTxHashes string, _bid *big.Int, _blockNumber uint64, _decayStartTimeStamp uint64, _decayEndTimeStamp uint64, _bidHash [32]byte, _bidSignature string, _sharedSecretKey string) ([32]byte, error) { + return _Preconfcommitmentstore.Contract.GetPreConfHash(&_Preconfcommitmentstore.CallOpts, _txnHash, _revertingTxHashes, _bid, _blockNumber, _decayStartTimeStamp, _decayEndTimeStamp, _bidHash, _bidSignature, _sharedSecretKey) } // GetTxnHashFromCommitment is a free data retrieval call binding the contract method 0xfc4fbe32. @@ -1085,15 +1105,15 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) ProxiableUUI return _Preconfcommitmentstore.Contract.ProxiableUUID(&_Preconfcommitmentstore.CallOpts) } -// VerifyBid is a free data retrieval call binding the contract method 0xd4c12558. +// VerifyBid is a free data retrieval call binding the contract method 0x20ee734c. // -// Solidity: function verifyBid(uint256 bid, uint64 blockNumber, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, bytes bidSignature) view returns(bytes32 messageDigest, address recoveredAddress) -func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) VerifyBid(opts *bind.CallOpts, bid *big.Int, blockNumber uint64, decayStartTimeStamp uint64, decayEndTimeStamp uint64, txnHash string, bidSignature []byte) (struct { +// Solidity: function verifyBid(uint256 bid, uint64 blockNumber, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, string revertingTxHashes, bytes bidSignature) view returns(bytes32 messageDigest, address recoveredAddress) +func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) VerifyBid(opts *bind.CallOpts, bid *big.Int, blockNumber uint64, decayStartTimeStamp uint64, decayEndTimeStamp uint64, txnHash string, revertingTxHashes string, bidSignature []byte) (struct { MessageDigest [32]byte RecoveredAddress common.Address }, error) { var out []interface{} - err := _Preconfcommitmentstore.contract.Call(opts, &out, "verifyBid", bid, blockNumber, decayStartTimeStamp, decayEndTimeStamp, txnHash, bidSignature) + err := _Preconfcommitmentstore.contract.Call(opts, &out, "verifyBid", bid, blockNumber, decayStartTimeStamp, decayEndTimeStamp, txnHash, revertingTxHashes, bidSignature) outstruct := new(struct { MessageDigest [32]byte @@ -1110,35 +1130,35 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) VerifyBid(opts *bin } -// VerifyBid is a free data retrieval call binding the contract method 0xd4c12558. +// VerifyBid is a free data retrieval call binding the contract method 0x20ee734c. // -// Solidity: function verifyBid(uint256 bid, uint64 blockNumber, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, bytes bidSignature) view returns(bytes32 messageDigest, address recoveredAddress) -func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) VerifyBid(bid *big.Int, blockNumber uint64, decayStartTimeStamp uint64, decayEndTimeStamp uint64, txnHash string, bidSignature []byte) (struct { +// Solidity: function verifyBid(uint256 bid, uint64 blockNumber, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, string revertingTxHashes, bytes bidSignature) view returns(bytes32 messageDigest, address recoveredAddress) +func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) VerifyBid(bid *big.Int, blockNumber uint64, decayStartTimeStamp uint64, decayEndTimeStamp uint64, txnHash string, revertingTxHashes string, bidSignature []byte) (struct { MessageDigest [32]byte RecoveredAddress common.Address }, error) { - return _Preconfcommitmentstore.Contract.VerifyBid(&_Preconfcommitmentstore.CallOpts, bid, blockNumber, decayStartTimeStamp, decayEndTimeStamp, txnHash, bidSignature) + return _Preconfcommitmentstore.Contract.VerifyBid(&_Preconfcommitmentstore.CallOpts, bid, blockNumber, decayStartTimeStamp, decayEndTimeStamp, txnHash, revertingTxHashes, bidSignature) } -// VerifyBid is a free data retrieval call binding the contract method 0xd4c12558. +// VerifyBid is a free data retrieval call binding the contract method 0x20ee734c. // -// Solidity: function verifyBid(uint256 bid, uint64 blockNumber, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, bytes bidSignature) view returns(bytes32 messageDigest, address recoveredAddress) -func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) VerifyBid(bid *big.Int, blockNumber uint64, decayStartTimeStamp uint64, decayEndTimeStamp uint64, txnHash string, bidSignature []byte) (struct { +// Solidity: function verifyBid(uint256 bid, uint64 blockNumber, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, string revertingTxHashes, bytes bidSignature) view returns(bytes32 messageDigest, address recoveredAddress) +func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) VerifyBid(bid *big.Int, blockNumber uint64, decayStartTimeStamp uint64, decayEndTimeStamp uint64, txnHash string, revertingTxHashes string, bidSignature []byte) (struct { MessageDigest [32]byte RecoveredAddress common.Address }, error) { - return _Preconfcommitmentstore.Contract.VerifyBid(&_Preconfcommitmentstore.CallOpts, bid, blockNumber, decayStartTimeStamp, decayEndTimeStamp, txnHash, bidSignature) + return _Preconfcommitmentstore.Contract.VerifyBid(&_Preconfcommitmentstore.CallOpts, bid, blockNumber, decayStartTimeStamp, decayEndTimeStamp, txnHash, revertingTxHashes, bidSignature) } -// VerifyPreConfCommitment is a free data retrieval call binding the contract method 0xd2e94c60. +// VerifyPreConfCommitment is a free data retrieval call binding the contract method 0xe93bbf26. // -// Solidity: function verifyPreConfCommitment(string txnHash, uint256 bid, uint64 blockNumber, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, bytes32 bidHash, bytes bidSignature, bytes commitmentSignature, bytes sharedSecretKey) view returns(bytes32 preConfHash, address commiterAddress) -func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) VerifyPreConfCommitment(opts *bind.CallOpts, txnHash string, bid *big.Int, blockNumber uint64, decayStartTimeStamp uint64, decayEndTimeStamp uint64, bidHash [32]byte, bidSignature []byte, commitmentSignature []byte, sharedSecretKey []byte) (struct { +// Solidity: function verifyPreConfCommitment((string,string,uint256,uint64,uint64,uint64,bytes32,bytes,bytes,bytes) params) view returns(bytes32 preConfHash, address commiterAddress) +func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) VerifyPreConfCommitment(opts *bind.CallOpts, params PreConfCommitmentStoreCommitmentParams) (struct { PreConfHash [32]byte CommiterAddress common.Address }, error) { var out []interface{} - err := _Preconfcommitmentstore.contract.Call(opts, &out, "verifyPreConfCommitment", txnHash, bid, blockNumber, decayStartTimeStamp, decayEndTimeStamp, bidHash, bidSignature, commitmentSignature, sharedSecretKey) + err := _Preconfcommitmentstore.contract.Call(opts, &out, "verifyPreConfCommitment", params) outstruct := new(struct { PreConfHash [32]byte @@ -1155,24 +1175,24 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreCaller) VerifyPreConfCommit } -// VerifyPreConfCommitment is a free data retrieval call binding the contract method 0xd2e94c60. +// VerifyPreConfCommitment is a free data retrieval call binding the contract method 0xe93bbf26. // -// Solidity: function verifyPreConfCommitment(string txnHash, uint256 bid, uint64 blockNumber, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, bytes32 bidHash, bytes bidSignature, bytes commitmentSignature, bytes sharedSecretKey) view returns(bytes32 preConfHash, address commiterAddress) -func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) VerifyPreConfCommitment(txnHash string, bid *big.Int, blockNumber uint64, decayStartTimeStamp uint64, decayEndTimeStamp uint64, bidHash [32]byte, bidSignature []byte, commitmentSignature []byte, sharedSecretKey []byte) (struct { +// Solidity: function verifyPreConfCommitment((string,string,uint256,uint64,uint64,uint64,bytes32,bytes,bytes,bytes) params) view returns(bytes32 preConfHash, address commiterAddress) +func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) VerifyPreConfCommitment(params PreConfCommitmentStoreCommitmentParams) (struct { PreConfHash [32]byte CommiterAddress common.Address }, error) { - return _Preconfcommitmentstore.Contract.VerifyPreConfCommitment(&_Preconfcommitmentstore.CallOpts, txnHash, bid, blockNumber, decayStartTimeStamp, decayEndTimeStamp, bidHash, bidSignature, commitmentSignature, sharedSecretKey) + return _Preconfcommitmentstore.Contract.VerifyPreConfCommitment(&_Preconfcommitmentstore.CallOpts, params) } -// VerifyPreConfCommitment is a free data retrieval call binding the contract method 0xd2e94c60. +// VerifyPreConfCommitment is a free data retrieval call binding the contract method 0xe93bbf26. // -// Solidity: function verifyPreConfCommitment(string txnHash, uint256 bid, uint64 blockNumber, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, bytes32 bidHash, bytes bidSignature, bytes commitmentSignature, bytes sharedSecretKey) view returns(bytes32 preConfHash, address commiterAddress) -func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) VerifyPreConfCommitment(txnHash string, bid *big.Int, blockNumber uint64, decayStartTimeStamp uint64, decayEndTimeStamp uint64, bidHash [32]byte, bidSignature []byte, commitmentSignature []byte, sharedSecretKey []byte) (struct { +// Solidity: function verifyPreConfCommitment((string,string,uint256,uint64,uint64,uint64,bytes32,bytes,bytes,bytes) params) view returns(bytes32 preConfHash, address commiterAddress) +func (_Preconfcommitmentstore *PreconfcommitmentstoreCallerSession) VerifyPreConfCommitment(params PreConfCommitmentStoreCommitmentParams) (struct { PreConfHash [32]byte CommiterAddress common.Address }, error) { - return _Preconfcommitmentstore.Contract.VerifyPreConfCommitment(&_Preconfcommitmentstore.CallOpts, txnHash, bid, blockNumber, decayStartTimeStamp, decayEndTimeStamp, bidHash, bidSignature, commitmentSignature, sharedSecretKey) + return _Preconfcommitmentstore.Contract.VerifyPreConfCommitment(&_Preconfcommitmentstore.CallOpts, params) } // Initialize is a paid mutator transaction binding the contract method 0xd8d0cbc1. @@ -1238,25 +1258,25 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreTransactorSession) Initiate return _Preconfcommitmentstore.Contract.InitiateSlash(&_Preconfcommitmentstore.TransactOpts, commitmentIndex, residualBidPercentAfterDecay) } -// OpenCommitment is a paid mutator transaction binding the contract method 0x7696c0b8. +// OpenCommitment is a paid mutator transaction binding the contract method 0x05880c6a. // -// Solidity: function openCommitment(bytes32 encryptedCommitmentIndex, uint256 bid, uint64 blockNumber, string txnHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, bytes bidSignature, bytes commitmentSignature, bytes sharedSecretKey) returns(bytes32 commitmentIndex) -func (_Preconfcommitmentstore *PreconfcommitmentstoreTransactor) OpenCommitment(opts *bind.TransactOpts, encryptedCommitmentIndex [32]byte, bid *big.Int, blockNumber uint64, txnHash string, decayStartTimeStamp uint64, decayEndTimeStamp uint64, bidSignature []byte, commitmentSignature []byte, sharedSecretKey []byte) (*types.Transaction, error) { - return _Preconfcommitmentstore.contract.Transact(opts, "openCommitment", encryptedCommitmentIndex, bid, blockNumber, txnHash, decayStartTimeStamp, decayEndTimeStamp, bidSignature, commitmentSignature, sharedSecretKey) +// Solidity: function openCommitment(bytes32 encryptedCommitmentIndex, uint256 bid, uint64 blockNumber, string txnHash, string revertingTxHashes, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, bytes bidSignature, bytes commitmentSignature, bytes sharedSecretKey) returns(bytes32 commitmentIndex) +func (_Preconfcommitmentstore *PreconfcommitmentstoreTransactor) OpenCommitment(opts *bind.TransactOpts, encryptedCommitmentIndex [32]byte, bid *big.Int, blockNumber uint64, txnHash string, revertingTxHashes string, decayStartTimeStamp uint64, decayEndTimeStamp uint64, bidSignature []byte, commitmentSignature []byte, sharedSecretKey []byte) (*types.Transaction, error) { + return _Preconfcommitmentstore.contract.Transact(opts, "openCommitment", encryptedCommitmentIndex, bid, blockNumber, txnHash, revertingTxHashes, decayStartTimeStamp, decayEndTimeStamp, bidSignature, commitmentSignature, sharedSecretKey) } -// OpenCommitment is a paid mutator transaction binding the contract method 0x7696c0b8. +// OpenCommitment is a paid mutator transaction binding the contract method 0x05880c6a. // -// Solidity: function openCommitment(bytes32 encryptedCommitmentIndex, uint256 bid, uint64 blockNumber, string txnHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, bytes bidSignature, bytes commitmentSignature, bytes sharedSecretKey) returns(bytes32 commitmentIndex) -func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) OpenCommitment(encryptedCommitmentIndex [32]byte, bid *big.Int, blockNumber uint64, txnHash string, decayStartTimeStamp uint64, decayEndTimeStamp uint64, bidSignature []byte, commitmentSignature []byte, sharedSecretKey []byte) (*types.Transaction, error) { - return _Preconfcommitmentstore.Contract.OpenCommitment(&_Preconfcommitmentstore.TransactOpts, encryptedCommitmentIndex, bid, blockNumber, txnHash, decayStartTimeStamp, decayEndTimeStamp, bidSignature, commitmentSignature, sharedSecretKey) +// Solidity: function openCommitment(bytes32 encryptedCommitmentIndex, uint256 bid, uint64 blockNumber, string txnHash, string revertingTxHashes, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, bytes bidSignature, bytes commitmentSignature, bytes sharedSecretKey) returns(bytes32 commitmentIndex) +func (_Preconfcommitmentstore *PreconfcommitmentstoreSession) OpenCommitment(encryptedCommitmentIndex [32]byte, bid *big.Int, blockNumber uint64, txnHash string, revertingTxHashes string, decayStartTimeStamp uint64, decayEndTimeStamp uint64, bidSignature []byte, commitmentSignature []byte, sharedSecretKey []byte) (*types.Transaction, error) { + return _Preconfcommitmentstore.Contract.OpenCommitment(&_Preconfcommitmentstore.TransactOpts, encryptedCommitmentIndex, bid, blockNumber, txnHash, revertingTxHashes, decayStartTimeStamp, decayEndTimeStamp, bidSignature, commitmentSignature, sharedSecretKey) } -// OpenCommitment is a paid mutator transaction binding the contract method 0x7696c0b8. +// OpenCommitment is a paid mutator transaction binding the contract method 0x05880c6a. // -// Solidity: function openCommitment(bytes32 encryptedCommitmentIndex, uint256 bid, uint64 blockNumber, string txnHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, bytes bidSignature, bytes commitmentSignature, bytes sharedSecretKey) returns(bytes32 commitmentIndex) -func (_Preconfcommitmentstore *PreconfcommitmentstoreTransactorSession) OpenCommitment(encryptedCommitmentIndex [32]byte, bid *big.Int, blockNumber uint64, txnHash string, decayStartTimeStamp uint64, decayEndTimeStamp uint64, bidSignature []byte, commitmentSignature []byte, sharedSecretKey []byte) (*types.Transaction, error) { - return _Preconfcommitmentstore.Contract.OpenCommitment(&_Preconfcommitmentstore.TransactOpts, encryptedCommitmentIndex, bid, blockNumber, txnHash, decayStartTimeStamp, decayEndTimeStamp, bidSignature, commitmentSignature, sharedSecretKey) +// Solidity: function openCommitment(bytes32 encryptedCommitmentIndex, uint256 bid, uint64 blockNumber, string txnHash, string revertingTxHashes, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, bytes bidSignature, bytes commitmentSignature, bytes sharedSecretKey) returns(bytes32 commitmentIndex) +func (_Preconfcommitmentstore *PreconfcommitmentstoreTransactorSession) OpenCommitment(encryptedCommitmentIndex [32]byte, bid *big.Int, blockNumber uint64, txnHash string, revertingTxHashes string, decayStartTimeStamp uint64, decayEndTimeStamp uint64, bidSignature []byte, commitmentSignature []byte, sharedSecretKey []byte) (*types.Transaction, error) { + return _Preconfcommitmentstore.Contract.OpenCommitment(&_Preconfcommitmentstore.TransactOpts, encryptedCommitmentIndex, bid, blockNumber, txnHash, revertingTxHashes, decayStartTimeStamp, decayEndTimeStamp, bidSignature, commitmentSignature, sharedSecretKey) } // RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. @@ -1547,6 +1567,7 @@ type PreconfcommitmentstoreCommitmentStored struct { DecayStartTimeStamp uint64 DecayEndTimeStamp uint64 TxnHash string + RevertingTxHashes string CommitmentHash [32]byte BidSignature []byte CommitmentSignature []byte @@ -1555,9 +1576,9 @@ type PreconfcommitmentstoreCommitmentStored struct { Raw types.Log // Blockchain specific contextual infos } -// FilterCommitmentStored is a free log retrieval operation binding the contract event 0x65a26490031434e303a64e52c432df3fc125c55d6e9f5f9287ca2d5aaa01ff9b. +// FilterCommitmentStored is a free log retrieval operation binding the contract event 0xe44dd4d002deb2c79cf08ce285a9d80c69753f31ca65c8e49f0a60d27ed9fea3. // -// Solidity: event CommitmentStored(bytes32 indexed commitmentIndex, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) +// Solidity: event CommitmentStored(bytes32 indexed commitmentIndex, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, string revertingTxHashes, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) func (_Preconfcommitmentstore *PreconfcommitmentstoreFilterer) FilterCommitmentStored(opts *bind.FilterOpts, commitmentIndex [][32]byte) (*PreconfcommitmentstoreCommitmentStoredIterator, error) { var commitmentIndexRule []interface{} @@ -1572,9 +1593,9 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreFilterer) FilterCommitmentS return &PreconfcommitmentstoreCommitmentStoredIterator{contract: _Preconfcommitmentstore.contract, event: "CommitmentStored", logs: logs, sub: sub}, nil } -// WatchCommitmentStored is a free log subscription operation binding the contract event 0x65a26490031434e303a64e52c432df3fc125c55d6e9f5f9287ca2d5aaa01ff9b. +// WatchCommitmentStored is a free log subscription operation binding the contract event 0xe44dd4d002deb2c79cf08ce285a9d80c69753f31ca65c8e49f0a60d27ed9fea3. // -// Solidity: event CommitmentStored(bytes32 indexed commitmentIndex, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) +// Solidity: event CommitmentStored(bytes32 indexed commitmentIndex, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, string revertingTxHashes, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) func (_Preconfcommitmentstore *PreconfcommitmentstoreFilterer) WatchCommitmentStored(opts *bind.WatchOpts, sink chan<- *PreconfcommitmentstoreCommitmentStored, commitmentIndex [][32]byte) (event.Subscription, error) { var commitmentIndexRule []interface{} @@ -1614,9 +1635,9 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreFilterer) WatchCommitmentSt }), nil } -// ParseCommitmentStored is a log parse operation binding the contract event 0x65a26490031434e303a64e52c432df3fc125c55d6e9f5f9287ca2d5aaa01ff9b. +// ParseCommitmentStored is a log parse operation binding the contract event 0xe44dd4d002deb2c79cf08ce285a9d80c69753f31ca65c8e49f0a60d27ed9fea3. // -// Solidity: event CommitmentStored(bytes32 indexed commitmentIndex, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) +// Solidity: event CommitmentStored(bytes32 indexed commitmentIndex, address bidder, address commiter, uint256 bid, uint64 blockNumber, bytes32 bidHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, string revertingTxHashes, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, uint64 dispatchTimestamp, bytes sharedSecretKey) func (_Preconfcommitmentstore *PreconfcommitmentstoreFilterer) ParseCommitmentStored(log types.Log) (*PreconfcommitmentstoreCommitmentStored, error) { event := new(PreconfcommitmentstoreCommitmentStored) if err := _Preconfcommitmentstore.contract.UnpackLog(event, "CommitmentStored", log); err != nil { @@ -2130,16 +2151,17 @@ func (it *PreconfcommitmentstoreSignatureVerifiedIterator) Close() error { // PreconfcommitmentstoreSignatureVerified represents a SignatureVerified event raised by the Preconfcommitmentstore contract. type PreconfcommitmentstoreSignatureVerified struct { - Signer common.Address - TxnHash string - Bid *big.Int - BlockNumber uint64 - Raw types.Log // Blockchain specific contextual infos + Signer common.Address + TxnHash string + RevertingTxHashes string + Bid *big.Int + BlockNumber uint64 + Raw types.Log // Blockchain specific contextual infos } -// FilterSignatureVerified is a free log retrieval operation binding the contract event 0xe872564fb7c047879c36afa1ab2c8a8466c69098cc6a38d2b2f36cc786e65c34. +// FilterSignatureVerified is a free log retrieval operation binding the contract event 0xf5fa3f7902916f0e4e2af218fa9a77809c54e64b77ec4061a205ec3b7ce5c35e. // -// Solidity: event SignatureVerified(address indexed signer, string txnHash, uint256 indexed bid, uint64 blockNumber) +// Solidity: event SignatureVerified(address indexed signer, string txnHash, string revertingTxHashes, uint256 indexed bid, uint64 blockNumber) func (_Preconfcommitmentstore *PreconfcommitmentstoreFilterer) FilterSignatureVerified(opts *bind.FilterOpts, signer []common.Address, bid []*big.Int) (*PreconfcommitmentstoreSignatureVerifiedIterator, error) { var signerRule []interface{} @@ -2159,9 +2181,9 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreFilterer) FilterSignatureVe return &PreconfcommitmentstoreSignatureVerifiedIterator{contract: _Preconfcommitmentstore.contract, event: "SignatureVerified", logs: logs, sub: sub}, nil } -// WatchSignatureVerified is a free log subscription operation binding the contract event 0xe872564fb7c047879c36afa1ab2c8a8466c69098cc6a38d2b2f36cc786e65c34. +// WatchSignatureVerified is a free log subscription operation binding the contract event 0xf5fa3f7902916f0e4e2af218fa9a77809c54e64b77ec4061a205ec3b7ce5c35e. // -// Solidity: event SignatureVerified(address indexed signer, string txnHash, uint256 indexed bid, uint64 blockNumber) +// Solidity: event SignatureVerified(address indexed signer, string txnHash, string revertingTxHashes, uint256 indexed bid, uint64 blockNumber) func (_Preconfcommitmentstore *PreconfcommitmentstoreFilterer) WatchSignatureVerified(opts *bind.WatchOpts, sink chan<- *PreconfcommitmentstoreSignatureVerified, signer []common.Address, bid []*big.Int) (event.Subscription, error) { var signerRule []interface{} @@ -2206,9 +2228,9 @@ func (_Preconfcommitmentstore *PreconfcommitmentstoreFilterer) WatchSignatureVer }), nil } -// ParseSignatureVerified is a log parse operation binding the contract event 0xe872564fb7c047879c36afa1ab2c8a8466c69098cc6a38d2b2f36cc786e65c34. +// ParseSignatureVerified is a log parse operation binding the contract event 0xf5fa3f7902916f0e4e2af218fa9a77809c54e64b77ec4061a205ec3b7ce5c35e. // -// Solidity: event SignatureVerified(address indexed signer, string txnHash, uint256 indexed bid, uint64 blockNumber) +// Solidity: event SignatureVerified(address indexed signer, string txnHash, string revertingTxHashes, uint256 indexed bid, uint64 blockNumber) func (_Preconfcommitmentstore *PreconfcommitmentstoreFilterer) ParseSignatureVerified(log types.Log) (*PreconfcommitmentstoreSignatureVerified, error) { event := new(PreconfcommitmentstoreSignatureVerified) if err := _Preconfcommitmentstore.contract.UnpackLog(event, "SignatureVerified", log); err != nil { diff --git a/contracts/contracts/PreConfCommitmentStore.sol b/contracts/contracts/PreConfCommitmentStore.sol index e197e504b..64144ba64 100644 --- a/contracts/contracts/PreConfCommitmentStore.sol +++ b/contracts/contracts/PreConfCommitmentStore.sol @@ -19,15 +19,15 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { /// @dev EIP-712 Type Hash for preconfirmation commitment bytes32 public constant EIP712_COMMITMENT_TYPEHASH = - keccak256( - "PreConfCommitment(string txnHash,uint256 bid,uint64 blockNumber,uint64 decayStartTimeStamp,uint64 decayEndTimeStamp,bytes32 bidHash,string signature,string sharedSecretKey)" - ); + keccak256( + "PreConfCommitment(string txnHash,string revertingTxHashes,uint256 bid,uint64 blockNumber,uint64 decayStartTimeStamp,uint64 decayEndTimeStamp,bytes32 bidHash,string signature,string sharedSecretKey)" + ); /// @dev EIP-712 Type Hash for preconfirmation bid bytes32 public constant EIP712_BID_TYPEHASH = - keccak256( - "PreConfBid(string txnHash,uint256 bid,uint64 blockNumber,uint64 decayStartTimeStamp,uint64 decayEndTimeStamp)" - ); + keccak256( + "PreConfBid(string txnHash,string revertingTxHashes,uint256 bid,uint64 blockNumber,uint64 decayStartTimeStamp,uint64 decayEndTimeStamp)" + ); // Represents the dispatch window in milliseconds uint64 public commitmentDispatchWindow; @@ -76,6 +76,7 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { uint64 decayStartTimeStamp; uint64 decayEndTimeStamp; string txnHash; + string revertingTxHashes; bytes32 commitmentHash; bytes bidSignature; bytes commitmentSignature; @@ -94,6 +95,7 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string txnHash, + string revertingTxHashes, bytes32 commitmentHash, bytes bidSignature, bytes commitmentSignature, @@ -101,6 +103,20 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { bytes sharedSecretKey ); + /// @dev Struct for all the commitment params to avoid too deep in the stack error + struct CommitmentParams { + string txnHash; + string revertingTxHashes; + uint256 bid; + uint64 blockNumber; + uint64 decayStartTimeStamp; + uint64 decayEndTimeStamp; + bytes32 bidHash; + bytes bidSignature; + bytes commitmentSignature; + bytes sharedSecretKey; + } + /// @dev Struct for all the information around encrypted preconfirmations commitment struct EncrPreConfCommitment { bool isUsed; @@ -123,6 +139,7 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { event SignatureVerified( address indexed signer, string txnHash, + string revertingTxHashes, uint256 indexed bid, uint64 blockNumber ); @@ -215,10 +232,12 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { * @param _txnHash transaction Hash. * @param _bid bid id. * @param _blockNumber block number + * @param _revertingTxHashes reverting transaction hashes. * @return digest it returns a digest that can be used for signing bids */ function getBidHash( string memory _txnHash, + string memory _revertingTxHashes, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, @@ -226,18 +245,19 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { ) public view returns (bytes32) { return ECDSA.toTypedDataHash( - DOMAIN_SEPARATOR_BID, - keccak256( - abi.encode( - EIP712_BID_TYPEHASH, - keccak256(abi.encodePacked(_txnHash)), - _bid, - _blockNumber, - _decayStartTimeStamp, - _decayEndTimeStamp - ) + DOMAIN_SEPARATOR_BID, + keccak256( + abi.encode( + EIP712_BID_TYPEHASH, + keccak256(abi.encodePacked(_txnHash)), + keccak256(abi.encodePacked(_revertingTxHashes)), + _bid, + _blockNumber, + _decayStartTimeStamp, + _decayEndTimeStamp ) - ); + ) + ); } /** @@ -245,11 +265,13 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { * @param _txnHash transaction Hash. * @param _bid bid id. * @param _blockNumber block number. + * @param _revertingTxHashes reverting transaction hashes. * @param _bidHash hash of the bid. * @return digest it returns a digest that can be used for signing bids. */ function getPreConfHash( string memory _txnHash, + string memory _revertingTxHashes, uint256 _bid, uint64 _blockNumber, uint64 _decayStartTimeStamp, @@ -258,25 +280,27 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { string memory _bidSignature, string memory _sharedSecretKey ) public view returns (bytes32) { + return ECDSA.toTypedDataHash( - DOMAIN_SEPARATOR_PRECONF, - keccak256( - abi.encode( - EIP712_COMMITMENT_TYPEHASH, - keccak256(abi.encodePacked(_txnHash)), - _bid, - _blockNumber, - _decayStartTimeStamp, - _decayEndTimeStamp, - keccak256( - abi.encodePacked(_bytes32ToHexString(_bidHash)) - ), - keccak256(abi.encodePacked(_bidSignature)), - keccak256(abi.encodePacked(_sharedSecretKey)) - ) + DOMAIN_SEPARATOR_PRECONF, + keccak256( + abi.encode( + EIP712_COMMITMENT_TYPEHASH, + keccak256(abi.encodePacked(_txnHash)), + keccak256(abi.encodePacked(_revertingTxHashes)), + _bid, + _blockNumber, + _decayStartTimeStamp, + _decayEndTimeStamp, + keccak256( + abi.encodePacked(_bytes32ToHexString(_bidHash)) + ), + keccak256(abi.encodePacked(_bidSignature)), + keccak256(abi.encodePacked(_sharedSecretKey)) ) - ); + ) + ); } /** @@ -284,6 +308,7 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { * @param bid bid id. * @param blockNumber block number. * @param txnHash transaction Hash. + * @param revertingTxHashes reverting transaction hashes. * @param bidSignature bid signature. * @return messageDigest returns the bid hash for given bid id. * @return recoveredAddress the address from the bid hash. @@ -294,10 +319,12 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, string memory txnHash, + string memory revertingTxHashes, bytes calldata bidSignature ) public view returns (bytes32 messageDigest, address recoveredAddress) { messageDigest = getBidHash( txnHash, + revertingTxHashes, bid, blockNumber, decayStartTimeStamp, @@ -308,38 +335,45 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { /** * @dev Verifies a pre-confirmation commitment by computing the hash and recovering the committer's address. - * @param txnHash The transaction hash associated with the commitment. - * @param bid The bid amount. - * @param blockNumber The block number at the time of the bid. - * @param bidHash The hash of the bid details. - * @param bidSignature The signature of the bid. - * @param commitmentSignature The signature of the commitment. + * @param params The commitment params associated with the commitment. * @return preConfHash The hash of the pre-confirmation commitment. * @return commiterAddress The address of the committer recovered from the commitment signature. */ + function verifyPreConfCommitment( - string memory txnHash, - uint256 bid, - uint64 blockNumber, - uint64 decayStartTimeStamp, - uint64 decayEndTimeStamp, - bytes32 bidHash, - bytes memory bidSignature, - bytes memory commitmentSignature, - bytes memory sharedSecretKey + CommitmentParams memory params ) public view returns (bytes32 preConfHash, address commiterAddress) { - preConfHash = getPreConfHash( - txnHash, - bid, - blockNumber, - decayStartTimeStamp, - decayEndTimeStamp, - bidHash, - _bytesToHexString(bidSignature), - _bytesToHexString(sharedSecretKey) + return _verifyPreConfCommitment(params); + } + + function _verifyPreConfCommitment( + CommitmentParams memory params + ) internal view returns (bytes32 preConfHash, address commiterAddress) { + preConfHash = _getPreConfHash(params); + commiterAddress = _recoverCommitterAddress(preConfHash, params.commitmentSignature); + } + + function _getPreConfHash( + CommitmentParams memory params + ) internal view returns (bytes32) { + return getPreConfHash( + params.txnHash, + params.revertingTxHashes, + params.bid, + params.blockNumber, + params.decayStartTimeStamp, + params.decayEndTimeStamp, + params.bidHash, + _bytesToHexString(params.bidSignature), + _bytesToHexString(params.sharedSecretKey) ); + } - commiterAddress = preConfHash.recover(commitmentSignature); + function _recoverCommitterAddress( + bytes32 preConfHash, + bytes memory commitmentSignature + ) internal pure returns (address) { + return preConfHash.recover(commitmentSignature); } /** @@ -352,11 +386,11 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { ) public pure returns (bytes32) { return keccak256( - abi.encodePacked( - commitment.commitmentHash, - commitment.commitmentSignature - ) - ); + abi.encodePacked( + commitment.commitmentHash, + commitment.commitmentSignature + ) + ); } /** @@ -369,11 +403,11 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { ) public pure returns (bytes32) { return keccak256( - abi.encodePacked( - commitment.commitmentDigest, - commitment.commitmentSignature - ) - ); + abi.encodePacked( + commitment.commitmentDigest, + commitment.commitmentSignature + ) + ); } /** @@ -382,6 +416,7 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { @param bid The bid amount @param blockNumber The block number @param txnHash The transaction hash + @param revertingTxHashes The reverting transaction hashes @param decayStartTimeStamp The start time of the decay @param decayEndTimeStamp The end time of the decay @param bidSignature The signature of the bid @@ -394,6 +429,7 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { uint256 bid, uint64 blockNumber, string memory txnHash, + string memory revertingTxHashes, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, bytes calldata bidSignature, @@ -406,6 +442,7 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { decayStartTimeStamp, decayEndTimeStamp, txnHash, + revertingTxHashes, bidSignature ); @@ -413,6 +450,7 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { { bytes32 commitmentDigest = getPreConfHash( txnHash, + revertingTxHashes, bid, blockNumber, decayStartTimeStamp, @@ -422,8 +460,8 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { _bytesToHexString(sharedSecretKey) ); EncrPreConfCommitment - memory encryptedCommitment = encryptedCommitments[ - encryptedCommitmentIndex + memory encryptedCommitment = encryptedCommitments[ + encryptedCommitmentIndex ]; require(!encryptedCommitment.isUsed, "Commitment already used"); @@ -444,7 +482,7 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { address winner = blockTracker.getBlockWinner(blockNumber); require( (msg.sender == winner && winner == commiterAddress) || - msg.sender == bidderAddress, + msg.sender == bidderAddress, "Caller is not a winner provider or bidder" ); @@ -458,6 +496,7 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { decayStartTimeStamp, decayEndTimeStamp, txnHash, + revertingTxHashes, commitmentDigest, bidSignature, commitmentSignature, @@ -469,7 +508,6 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { // Store commitment commitments[commitmentIndex] = newCommitment; - // Mark the encrypted commitment as used encryptedCommitments[encryptedCommitmentIndex].isUsed = true; @@ -492,6 +530,7 @@ contract PreConfCommitmentStore is OwnableUpgradeable, UUPSUpgradeable { decayStartTimeStamp, decayEndTimeStamp, txnHash, + revertingTxHashes, commitmentDigest, bidSignature, commitmentSignature, diff --git a/contracts/contracts/interfaces/IPreConfCommitmentStore.sol b/contracts/contracts/interfaces/IPreConfCommitmentStore.sol index e9ef66b47..214b0429a 100644 --- a/contracts/contracts/interfaces/IPreConfCommitmentStore.sol +++ b/contracts/contracts/interfaces/IPreConfCommitmentStore.sol @@ -19,10 +19,12 @@ interface IPreConfCommitmentStore { uint64 decayStartTimeStamp; uint64 decayEndTimeStamp; string txnHash; + string revertingTxHashes; bytes32 commitmentHash; bytes bidSignature; bytes commitmentSignature; uint64 dispatchTimestamp; + bytes sharedSecretKey; } event SignatureVerified( @@ -63,6 +65,7 @@ interface IPreConfCommitmentStore { uint64 bid, uint64 blockNumber, string memory txnHash, + string memory revertingTxHashes, string memory commitmentHash, uint64 decayStartTimeStamp, uint64 decayEndTimeStamp, diff --git a/contracts/test/OracleTest.sol b/contracts/test/OracleTest.sol index 6d481e6cf..fb79c0076 100644 --- a/contracts/test/OracleTest.sol +++ b/contracts/test/OracleTest.sol @@ -11,6 +11,7 @@ import "../contracts/BlockTracker.sol"; import {Upgrades} from "openzeppelin-foundry-upgrades/Upgrades.sol"; import {WindowFromBlockNumber} from "../contracts/utils/WindowFromBlockNumber.sol"; +import "forge-std/console.sol"; contract OracleTest is Test { address public owner; @@ -61,7 +62,7 @@ contract OracleTest is Test { function setUp() public { testNumber = 2; testNumber2 = 2; - sharedSecretKey = abi.encodePacked(keccak256("0xsecret")); + sharedSecretKey = bytes("0xsecret"); _testCommitmentAliceBob = TestCommitment( 2, 2, @@ -166,6 +167,8 @@ contract OracleTest is Test { function test_process_commitment_payment_payout() public { string memory txn = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d08"; + string + memory revertingTxHashes = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d12"; uint64 blockNumber = uint64(blocksPerWindow + 2); uint64 bid = 2; (address bidder, uint256 bidderPk) = makeAddrAndKey("alice"); @@ -186,6 +189,7 @@ contract OracleTest is Test { bid, blockNumber, txn, + revertingTxHashes, bidderPk, providerPk, provider, @@ -211,6 +215,8 @@ contract OracleTest is Test { function test_process_commitment_slash() public { string memory txn = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d08"; + string + memory revertingTxHashes = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d12"; uint64 blockNumber = 200; uint64 bid = 200; (address bidder, uint256 bidderPk) = makeAddrAndKey("alice"); @@ -231,6 +237,7 @@ contract OracleTest is Test { bid, blockNumber, txn, + revertingTxHashes, bidderPk, providerPk, provider, @@ -260,6 +267,8 @@ contract OracleTest is Test { memory txn1 = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d08"; string memory txn2 = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d09"; + string + memory revertingTxHashes = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d12"; uint64 blockNumber = uint64(blocksPerWindow + 2); uint64 bid = 100; (address bidder, uint256 bidderPk) = makeAddrAndKey("alice"); @@ -282,6 +291,7 @@ contract OracleTest is Test { bid, blockNumber, txn1, + revertingTxHashes, bidderPk, providerPk, provider, @@ -291,6 +301,7 @@ contract OracleTest is Test { bid, blockNumber, txn2, + revertingTxHashes, bidderPk, providerPk, provider, @@ -335,6 +346,8 @@ contract OracleTest is Test { memory txn3 = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d10"; string memory txn4 = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d11"; + string + memory revertingTxHashes = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d12"; uint64 blockNumber = 201; uint64 bid = 5; (address bidder, uint256 bidderPk) = makeAddrAndKey("alice"); @@ -355,6 +368,7 @@ contract OracleTest is Test { bid, blockNumber, txn1, + revertingTxHashes, bidderPk, providerPk, provider, @@ -364,6 +378,7 @@ contract OracleTest is Test { bid, blockNumber, txn2, + revertingTxHashes, bidderPk, providerPk, provider, @@ -373,6 +388,7 @@ contract OracleTest is Test { bid, blockNumber, txn3, + revertingTxHashes, bidderPk, providerPk, provider, @@ -382,6 +398,7 @@ contract OracleTest is Test { bid, blockNumber, txn4, + revertingTxHashes, bidderPk, providerPk, provider, @@ -445,6 +462,7 @@ contract OracleTest is Test { txnHashes[ 3 ] = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d11"; + string memory revertingTxHashes = "0x6d9c53ad81249775f8c082b11ac293b2e19194ff791bd1c4fd37683310e90d12"; uint64 blockNumber = uint64(blocksPerWindow + 2); uint64 bid = 5; (address bidder, uint256 bidderPk) = makeAddrAndKey("alice"); @@ -474,6 +492,7 @@ contract OracleTest is Test { bid, blockNumber, txnHashes[i], + revertingTxHashes, 10, 20, bidderPk, @@ -494,6 +513,7 @@ contract OracleTest is Test { bid, blockNumber, txnHashes[i], + revertingTxHashes, 10, 20, bidSignatures[i], @@ -502,7 +522,6 @@ contract OracleTest is Test { ); vm.stopPrank(); } - vm.startPrank(address(0x6d503Fd50142C7C469C7c6B64794B55bfa6883f3)); for (uint256 i = 0; i < commitments.length; i++) { vm.expectEmit(true, false, false, true); @@ -524,24 +543,29 @@ contract OracleTest is Test { uint64 bid, uint64 blockNumber, string memory txnHash, + string memory revertingTxHashes, uint256 bidderPk, uint256 signerPk, address provider, uint64 dispatchTimestamp ) public returns (bytes32 commitmentIndex) { - bytes32 bidHash = getBidHash(txnHash, bid, blockNumber); + bytes32 bidHash = getBidHash(txnHash, revertingTxHashes, bid, blockNumber); bytes memory bidSignature = getBidSignature(bidderPk, bidHash); + bytes32 commitmentHash = getCommitmentHash( txnHash, + revertingTxHashes, bid, blockNumber, bidHash, bidSignature ); + bytes memory commitmentSignature = getCommitmentSignature( signerPk, commitmentHash ); + bytes32 encryptedCommitmentIndex = storeEncryptedCommitment( provider, @@ -557,6 +581,7 @@ contract OracleTest is Test { bid, blockNumber, txnHash, + revertingTxHashes, bidSignature, commitmentSignature ); @@ -565,12 +590,14 @@ contract OracleTest is Test { function getBidHash( string memory txnHash, + string memory revertingTxHashes, uint64 bid, uint64 blockNumber ) public view returns (bytes32) { return preConfCommitmentStore.getBidHash( txnHash, + revertingTxHashes, bid, blockNumber, 10, @@ -588,6 +615,7 @@ contract OracleTest is Test { function getCommitmentHash( string memory txnHash, + string memory revertingTxHashes, uint64 bid, uint64 blockNumber, bytes32 bidHash, @@ -596,6 +624,7 @@ contract OracleTest is Test { return preConfCommitmentStore.getPreConfHash( txnHash, + revertingTxHashes, bid, blockNumber, 10, @@ -644,6 +673,7 @@ contract OracleTest is Test { uint64 bid, uint64 blockNumber, string memory txnHash, + string memory revertingTxHashes, bytes memory bidSignature, bytes memory commitmentSignature ) public returns (bytes32) { @@ -653,6 +683,7 @@ contract OracleTest is Test { bid, blockNumber, txnHash, + revertingTxHashes, 10, 20, bidSignature, @@ -668,6 +699,7 @@ contract OracleTest is Test { uint64 bid, uint64 blockNumber, string memory txnHash, + string memory revertingTxHashes, uint64 decayStartTimestamp, uint64 decayEndTimestamp, uint256 bidderPk, @@ -683,6 +715,7 @@ contract OracleTest is Test { { bytes32 bidHash = preConfCommitmentStore.getBidHash( txnHash, + revertingTxHashes, bid, blockNumber, decayStartTimestamp, @@ -694,6 +727,7 @@ contract OracleTest is Test { bytes32 commitmentHash = preConfCommitmentStore.getPreConfHash( txnHash, + revertingTxHashes, bid, blockNumber, decayStartTimestamp, diff --git a/contracts/test/PreConfirmationConfTest.sol b/contracts/test/PreConfirmationConfTest.sol index e9390dc58..8b3540c94 100644 --- a/contracts/test/PreConfirmationConfTest.sol +++ b/contracts/test/PreConfirmationConfTest.sol @@ -17,6 +17,7 @@ contract TestPreConfCommitmentStore is Test { uint256 bid; uint64 blockNumber; string txnHash; + string revertingTxHashes; uint64 decayStartTimestamp; uint64 decayEndTimestamp; bytes32 bidDigest; @@ -44,12 +45,13 @@ contract TestPreConfCommitmentStore is Test { 2, 2, "0xkartik", + "0xkartik", 10, 20, - 0x56c06a13be335eba981b780ea45dff258a7c429d0e9d993235ef2d3a7e435df8, - 0x9d954942ad3f6cb41ccd029869be7b28036270b4754665a3783c2d6bf0ef7d08, - hex"2e7df27808c72d7d5b2543bb63b06c0ae2144e021593b8d2a7cca6a3fb2d9c4b1a82dd2a07266de9364d255bdb709476ad96b826ec855efb528eaff66682997e1c", - hex"682a1bc8659a0d2616f579ca0e0944d4e21911e65561b7d9ae7dba36c5a5b699248f1c93e8e6f52492ee6c3cb0f34f20f5a97fb2653c5a67200e1de9254389e11c", + 0x9890bcda118cfabed02ff3b9d05a54dca5310e9ace3b05f259f4731f58ad0900, + 0x8257770d4be5c4b622e6bd6b45ff8deb6602235f3aa844b774eb21800eb4923a, + hex"f9b66c6d57dac947a3aa2b37010df745592cf57f907d437767bc0af6d44b3dc1112168e4cab311d6dfddf7f58c0d07bb95403fca2cc48d4450e088cf9ee894c81b", + hex"8101af732be6879be2cea25a792b3dcc8a5372b5e7636e8348445351a6dd079c534bcaf61e3f7fb4f9f45238e4068a8a5fe20d0204c7644d25b12c60fa9540421c", 15, bytes("0xsecret") ); @@ -119,6 +121,68 @@ contract TestPreConfCommitmentStore is Test { ); } + function test_getBidHash() public { + // Step 1: Prepare the test commitment data + PreConfCommitmentStore.CommitmentParams memory testCommitment = PreConfCommitmentStore.CommitmentParams({ + txnHash: "0xkartik", + revertingTxHashes: "0xkartik", + bid: 2, + blockNumber: 2, + decayStartTimeStamp: 10, + decayEndTimeStamp: 20, + sharedSecretKey: bytes("0xsecret"), + bidHash: hex"9890bcda118cfabed02ff3b9d05a54dca5310e9ace3b05f259f4731f58ad0900", + bidSignature: hex"c2ab6e530f6b09337e53e1192857fa10017cdb488cf2a07e0aa4457571492b8c6bff93cbda4e003336656b4ecf8ff46bd1d408b310acdf07be4925a1a8fee4471c", + commitmentSignature: hex"5b3000290d4f347b94146eb37f66d5368aed18fb8713bf78620abe40ae3de7f635f7ed161801c31ea10e736d88e6fd2a2286bbd59385161dd24c9fefd2568f341b" + }); + // Step 2: Calculate the bid hash using the getBidHash function + bytes32 bidHash = preConfCommitmentStore.getBidHash( + testCommitment.txnHash, + testCommitment.revertingTxHashes, + testCommitment.bid, + testCommitment.blockNumber, + testCommitment.decayStartTimeStamp, + testCommitment.decayEndTimeStamp + ); + + // Add a bob private key and console log the key + (address bob, uint256 bobPk) = makeAddrAndKey("alice"); + + + // Make a signature on the bid hash + (uint8 v, bytes32 r, bytes32 s) = vm.sign(bobPk, bidHash); + bytes memory bidSignature = abi.encodePacked(r, s, v); + + + // Step 3: Calculate the commitment hash using the getPreConfHash function + bytes32 commitmentHash = preConfCommitmentStore.getPreConfHash( + testCommitment.txnHash, + testCommitment.revertingTxHashes, + testCommitment.bid, + testCommitment.blockNumber, + testCommitment.decayStartTimeStamp, + testCommitment.decayEndTimeStamp, + bidHash, + _bytesToHexString(bidSignature), + _bytesToHexString(testCommitment.sharedSecretKey) + ); + + // Step 4: Verify the bid hash is correctly generated and not zero + assert(bidHash != bytes32(0)); + + // Optional: Log the bid hash for debugging purposes + + + // Step 5: Verify the commitment hash is correctly generated and not zero + assert(commitmentHash != bytes32(0)); + // Log the commitment hash for debugging purposes + + + + // Optional: Log the commitment hash for debugging purposes + + } + function test_Initialize() public view { assertEq(preConfCommitmentStore.oracle(), feeRecipient); assertEq( @@ -150,10 +214,10 @@ contract TestPreConfCommitmentStore is Test { // Step 2: Store the commitment bytes32 commitmentIndex = preConfCommitmentStore .storeEncryptedCommitment( - commitmentDigest, - commitmentSignature, - 1000 - ); + commitmentDigest, + commitmentSignature, + 1000 + ); // Step 3: Verify the results // a. Check that the commitment index is correctly generated and not zero @@ -161,9 +225,9 @@ contract TestPreConfCommitmentStore is Test { // b. Retrieve the commitment by index and verify its properties PreConfCommitmentStore.EncrPreConfCommitment - memory commitment = preConfCommitmentStore.getEncryptedCommitment( - commitmentIndex - ); + memory commitment = preConfCommitmentStore.getEncryptedCommitment( + commitmentIndex + ); // c. Assertions to verify the stored commitment matches the input assertEq(commitment.commiter, committer); @@ -196,7 +260,7 @@ contract TestPreConfCommitmentStore is Test { } function test_StoreCommitmentFailureDueToTimestampValidationWithNewWindow() - public + public { bytes32 commitmentDigest = keccak256( abi.encodePacked("commitment data") @@ -244,6 +308,7 @@ contract TestPreConfCommitmentStore is Test { function test_GetBidHash() public view { bytes32 bidHash = preConfCommitmentStore.getBidHash( _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.decayStartTimestamp, @@ -254,9 +319,10 @@ contract TestPreConfCommitmentStore is Test { function test_GetCommitmentDigest() public { (, uint256 bidderPk) = makeAddrAndKey("alice"); - + bytes32 bidHash = preConfCommitmentStore.getBidHash( _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.decayStartTimestamp, @@ -265,10 +331,10 @@ contract TestPreConfCommitmentStore is Test { (uint8 v, bytes32 r, bytes32 s) = vm.sign(bidderPk, bidHash); bytes memory signature = abi.encodePacked(r, s, v); - console.logBytes(signature); bytes memory sharedSecretKey = bytes("0xsecret"); bytes32 preConfHash = preConfCommitmentStore.getPreConfHash( _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.decayStartTimestamp, @@ -282,7 +348,8 @@ contract TestPreConfCommitmentStore is Test { (, uint256 providerPk) = makeAddrAndKey("bob"); (v, r, s) = vm.sign(providerPk, preConfHash); signature = abi.encodePacked(r, s, v); - console.logBytes(signature); + + } function _bytes32ToHexString( @@ -306,6 +373,7 @@ contract TestPreConfCommitmentStore is Test { // Step 1: Verify that the commitment has not been used before verifyCommitmentNotUsed( _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.decayStartTimestamp, @@ -322,6 +390,7 @@ contract TestPreConfCommitmentStore is Test { _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.decayStartTimestamp, _testCommitmentAliceBob.decayEndTimestamp, _testCommitmentAliceBob.bidSignature, @@ -341,6 +410,7 @@ contract TestPreConfCommitmentStore is Test { _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.decayStartTimestamp, _testCommitmentAliceBob.decayEndTimestamp, _testCommitmentAliceBob.bidSignature, @@ -356,6 +426,7 @@ contract TestPreConfCommitmentStore is Test { _testCommitmentAliceBob.decayStartTimestamp, _testCommitmentAliceBob.decayEndTimestamp, _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bidSignature, _testCommitmentAliceBob.commitmentSignature, _testCommitmentAliceBob.sharedSecretKey @@ -368,6 +439,7 @@ contract TestPreConfCommitmentStore is Test { function verifyCommitmentNotUsed( string memory txnHash, + string memory revertingTxHashes, uint256 bid, uint64 blockNumber, uint64 decayStartTimestamp, @@ -376,6 +448,7 @@ contract TestPreConfCommitmentStore is Test { ) public view returns (bytes32) { bytes32 bidHash = preConfCommitmentStore.getBidHash( txnHash, + revertingTxHashes, bid, blockNumber, decayStartTimestamp, @@ -384,6 +457,7 @@ contract TestPreConfCommitmentStore is Test { bytes memory sharedSecretKey = abi.encodePacked(keccak256("0xsecret")); bytes32 preConfHash = preConfCommitmentStore.getPreConfHash( txnHash, + revertingTxHashes, bid, blockNumber, decayStartTimestamp, @@ -393,7 +467,7 @@ contract TestPreConfCommitmentStore is Test { _bytesToHexString(sharedSecretKey) ); - (bool isUsed, , , , , , , , , , , , , ) = preConfCommitmentStore + (bool isUsed, , , , , , , , , , , , , ,) = preConfCommitmentStore .commitments(preConfHash); assertEq(isUsed, false); @@ -405,6 +479,7 @@ contract TestPreConfCommitmentStore is Test { uint256 bid, uint64 blockNumber, string memory txnHash, + string memory revertingTxHashes, uint64 decayStartTimestamp, uint64 decayEndTimestamp, bytes memory bidSignature, @@ -414,6 +489,7 @@ contract TestPreConfCommitmentStore is Test { ) public returns (bytes32) { bytes32 bidHash = preConfCommitmentStore.getBidHash( txnHash, + revertingTxHashes, bid, blockNumber, decayStartTimestamp, @@ -422,6 +498,7 @@ contract TestPreConfCommitmentStore is Test { bytes32 commitmentHash = preConfCommitmentStore.getPreConfHash( txnHash, + revertingTxHashes, bid, blockNumber, decayStartTimestamp, @@ -433,10 +510,10 @@ contract TestPreConfCommitmentStore is Test { vm.startPrank(commiter); bytes32 commitmentIndex = preConfCommitmentStore .storeEncryptedCommitment( - commitmentHash, - commitmentSignature, - dispatchTimestamp - ); + commitmentHash, + commitmentSignature, + dispatchTimestamp + ); vm.stopPrank(); return commitmentIndex; } @@ -447,6 +524,7 @@ contract TestPreConfCommitmentStore is Test { uint256 bid, uint64 blockNumber, string memory txnHash, + string memory revertingTxHashes, uint64 decayStartTimestamp, uint64 decayEndTimestamp, bytes memory bidSignature, @@ -459,6 +537,7 @@ contract TestPreConfCommitmentStore is Test { bid, blockNumber, txnHash, + revertingTxHashes, decayStartTimestamp, decayEndTimestamp, bidSignature, @@ -476,25 +555,28 @@ contract TestPreConfCommitmentStore is Test { uint64 decayStartTimestamp, uint64 decayEndTimestamp, string memory txnHash, + string memory revertingTxHashes, bytes memory bidSignature, bytes memory commitmentSignature, bytes memory sharedSecretKey ) public view { PreConfCommitmentStore.PreConfCommitment - memory commitment = preConfCommitmentStore.getCommitment(index); - - (, address commiterAddress) = preConfCommitmentStore - .verifyPreConfCommitment( - txnHash, - bid, - blockNumber, - decayStartTimestamp, - decayEndTimestamp, - commitment.bidHash, - bidSignature, - commitmentSignature, - sharedSecretKey - ); + memory commitment = preConfCommitmentStore.getCommitment(index); + + PreConfCommitmentStore.CommitmentParams memory commitmentParams = PreConfCommitmentStore.CommitmentParams({ + txnHash: txnHash, + revertingTxHashes: revertingTxHashes, + bid: bid, + blockNumber: blockNumber, + decayStartTimeStamp: decayStartTimestamp, + decayEndTimeStamp: decayEndTimestamp, + bidHash: commitment.bidHash, + bidSignature: bidSignature, + commitmentSignature: commitmentSignature, + sharedSecretKey: sharedSecretKey + }); + + (, address commiterAddress) = preConfCommitmentStore.verifyPreConfCommitment(commitmentParams); assertNotEq(commiterAddress, address(0)); assertEq(commitment.bid, bid, "Stored bid should match input bid"); @@ -532,6 +614,7 @@ contract TestPreConfCommitmentStore is Test { // Step 1: Verify that the commitment has not been used before verifyCommitmentNotUsed( _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.decayStartTimestamp, @@ -541,11 +624,13 @@ contract TestPreConfCommitmentStore is Test { // Step 2: Store the commitment (address commiter, ) = makeAddrAndKey("bob"); vm.deal(commiter, 5 ether); + bytes32 commitmentIndex = storeCommitment( commiter, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.decayStartTimestamp, _testCommitmentAliceBob.decayEndTimestamp, _testCommitmentAliceBob.bidSignature, @@ -554,8 +639,8 @@ contract TestPreConfCommitmentStore is Test { _testCommitmentAliceBob.sharedSecretKey ); PreConfCommitmentStore.EncrPreConfCommitment - memory storedCommitment = preConfCommitmentStore - .getEncryptedCommitment(commitmentIndex); + memory storedCommitment = preConfCommitmentStore + .getEncryptedCommitment(commitmentIndex); assertEq( storedCommitment.commitmentDigest, @@ -575,9 +660,9 @@ contract TestPreConfCommitmentStore is Test { vm.prank(bidder); uint256 depositWindow = WindowFromBlockNumber .getWindowFromBlockNumber( - _testCommitmentAliceBob.blockNumber, - blocksPerWindow - ); + _testCommitmentAliceBob.blockNumber, + blocksPerWindow + ); bidderRegistry.depositForSpecificWindow{value: 2 ether}( depositWindow ); @@ -585,6 +670,7 @@ contract TestPreConfCommitmentStore is Test { // Step 1: Verify that the commitment has not been used before bytes32 bidHash = verifyCommitmentNotUsed( _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.decayStartTimestamp, @@ -594,6 +680,7 @@ contract TestPreConfCommitmentStore is Test { bytes32 preConfHash = preConfCommitmentStore.getPreConfHash( _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.decayStartTimestamp, @@ -604,7 +691,7 @@ contract TestPreConfCommitmentStore is Test { ); // Verify that the commitment has not been set before - (bool isUsed, , , , , , , , , , , , , ) = preConfCommitmentStore + (bool isUsed, , , , , , , , , , , , , ,) = preConfCommitmentStore .commitments(preConfHash); assert(isUsed == false); (address commiter, ) = makeAddrAndKey("bob"); @@ -614,6 +701,7 @@ contract TestPreConfCommitmentStore is Test { _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.decayStartTimestamp, _testCommitmentAliceBob.decayEndTimestamp, _testCommitmentAliceBob.bidSignature, @@ -635,6 +723,7 @@ contract TestPreConfCommitmentStore is Test { _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.decayStartTimestamp, _testCommitmentAliceBob.decayEndTimestamp, _testCommitmentAliceBob.bidSignature, @@ -644,8 +733,8 @@ contract TestPreConfCommitmentStore is Test { vm.prank(feeRecipient); preConfCommitmentStore.initiateSlash(index, 100); - (isUsed, , , , , , , , , , , , , ) = preConfCommitmentStore - .commitments(index); + (isUsed, , , , , , , , , , , , , ,) = preConfCommitmentStore + .commitments(index); // Verify that the commitment has been deleted assert(isUsed == true); } @@ -660,9 +749,9 @@ contract TestPreConfCommitmentStore is Test { vm.prank(bidder); uint256 depositWindow = WindowFromBlockNumber .getWindowFromBlockNumber( - _testCommitmentAliceBob.blockNumber, - blocksPerWindow - ); + _testCommitmentAliceBob.blockNumber, + blocksPerWindow + ); bidderRegistry.depositForSpecificWindow{value: 2 ether}( depositWindow ); @@ -670,6 +759,7 @@ contract TestPreConfCommitmentStore is Test { // Step 1: Verify that the commitment has not been used before bytes32 bidHash = verifyCommitmentNotUsed( _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.decayStartTimestamp, @@ -678,6 +768,7 @@ contract TestPreConfCommitmentStore is Test { ); bytes32 preConfHash = preConfCommitmentStore.getPreConfHash( _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.decayStartTimestamp, @@ -686,9 +777,9 @@ contract TestPreConfCommitmentStore is Test { _bytesToHexString(_testCommitmentAliceBob.bidSignature), _bytesToHexString(_testCommitmentAliceBob.sharedSecretKey) ); - + // Verify that the commitment has not been used before - (bool isUsed, , , , , , , , , , , , , ) = preConfCommitmentStore + (bool isUsed, , , , , , , , , , , , , ,) = preConfCommitmentStore .commitments(preConfHash); assert(isUsed == false); (address commiter, ) = makeAddrAndKey("bob"); @@ -698,6 +789,7 @@ contract TestPreConfCommitmentStore is Test { _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.decayStartTimestamp, _testCommitmentAliceBob.decayEndTimestamp, _testCommitmentAliceBob.bidSignature, @@ -718,6 +810,7 @@ contract TestPreConfCommitmentStore is Test { _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.decayStartTimestamp, _testCommitmentAliceBob.decayEndTimestamp, _testCommitmentAliceBob.bidSignature, @@ -727,8 +820,8 @@ contract TestPreConfCommitmentStore is Test { vm.prank(feeRecipient); preConfCommitmentStore.initiateReward(index, 100); - (isUsed, , , , , , , , , , , , , ) = preConfCommitmentStore - .commitments(index); + (isUsed, , , , , , , , , , , , , ,) = preConfCommitmentStore + .commitments(index); // Verify that the commitment has been marked as used assert(isUsed == true); // commitmentHash value is internal to contract and not asserted @@ -741,9 +834,9 @@ contract TestPreConfCommitmentStore is Test { (address bidder, ) = makeAddrAndKey("alice"); uint256 depositWindow = WindowFromBlockNumber .getWindowFromBlockNumber( - _testCommitmentAliceBob.blockNumber, - blocksPerWindow - ); + _testCommitmentAliceBob.blockNumber, + blocksPerWindow + ); vm.deal(bidder, 5 ether); vm.prank(bidder); bidderRegistry.depositForSpecificWindow{value: 2 ether}( @@ -753,6 +846,7 @@ contract TestPreConfCommitmentStore is Test { // Step 1: Verify that the commitment has not been used before bytes32 bidHash = verifyCommitmentNotUsed( _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.decayStartTimestamp, @@ -761,6 +855,7 @@ contract TestPreConfCommitmentStore is Test { ); bytes32 preConfHash = preConfCommitmentStore.getPreConfHash( _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.decayStartTimestamp, @@ -771,7 +866,7 @@ contract TestPreConfCommitmentStore is Test { ); // Verify that the commitment has not been used before - (bool isUsed, , , , , , , , , , , , , ) = preConfCommitmentStore + (bool isUsed, , , , , , , , , , , , , ,) = preConfCommitmentStore .commitments(preConfHash); assert(isUsed == false); (address commiter, ) = makeAddrAndKey("bob"); @@ -782,6 +877,7 @@ contract TestPreConfCommitmentStore is Test { _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.decayStartTimestamp, _testCommitmentAliceBob.decayEndTimestamp, _testCommitmentAliceBob.bidSignature, @@ -802,6 +898,7 @@ contract TestPreConfCommitmentStore is Test { _testCommitmentAliceBob.bid, _testCommitmentAliceBob.blockNumber, _testCommitmentAliceBob.txnHash, + _testCommitmentAliceBob.revertingTxHashes, _testCommitmentAliceBob.decayStartTimestamp, _testCommitmentAliceBob.decayEndTimestamp, _testCommitmentAliceBob.bidSignature, @@ -812,8 +909,8 @@ contract TestPreConfCommitmentStore is Test { vm.prank(feeRecipient); preConfCommitmentStore.initiateReward(index, 0); - (isUsed, , , , , , , , , , , , , ) = preConfCommitmentStore - .commitments(index); + (isUsed, , , , , , , , , , , , , ,) = preConfCommitmentStore + .commitments(index); // Verify that the commitment has been marked as used assert(isUsed == true); // commitmentHash value is internal to contract and not asserted @@ -834,4 +931,4 @@ contract TestPreConfCommitmentStore is Test { } return string(_string); } -} +} \ No newline at end of file diff --git a/oracle/pkg/updater/updater.go b/oracle/pkg/updater/updater.go index 1f1ae92e5..3b1f841c5 100644 --- a/oracle/pkg/updater/updater.go +++ b/oracle/pkg/updater/updater.go @@ -336,12 +336,22 @@ func (u *Updater) handleOpenedCommitment( ) commitmentTxnHashes := strings.Split(update.TxnHash, ",") + u.logger.Debug("commitmentTxnHashes", "commitmentTxnHashes", commitmentTxnHashes) + revertableTxns := strings.Split(update.RevertingTxHashes, ",") + u.logger.Debug("revertableTxns", "revertableTxns", revertableTxns) + + // Create a map for revertable transactions + revertableTxnsMap := make(map[string]bool) + for _, txn := range revertableTxns { + revertableTxnsMap[txn] = true + } + // Ensure Bundle is atomic and present in the block for i := 0; i < len(commitmentTxnHashes); i++ { txnDetails, found := txns[commitmentTxnHashes[i]] - if !found || txnDetails.PosInBlock != (txns[commitmentTxnHashes[0]].PosInBlock)+i || !txnDetails.Succeeded { + if !found || txnDetails.PosInBlock != (txns[commitmentTxnHashes[0]].PosInBlock)+i || (!txnDetails.Succeeded && !revertableTxnsMap[commitmentTxnHashes[i]]) { u.logger.Info( - "bundle does not satsify commited requirements", + "bundle does not satisfy committed requirements", "commitmentIdx", common.Bytes2Hex(update.CommitmentIndex[:]), "txnHash", update.TxnHash, "blockNumber", update.BlockNumber, @@ -349,6 +359,7 @@ func (u *Updater) handleOpenedCommitment( "posInBlock", txnDetails.PosInBlock, "succeeded", txnDetails.Succeeded, "expectedPosInBlock", txns[commitmentTxnHashes[0]].PosInBlock+i, + "revertible", revertableTxnsMap[commitmentTxnHashes[i]], ) // The committer did not include the transactions in the block diff --git a/oracle/pkg/updater/updater_test.go b/oracle/pkg/updater/updater_test.go index 12176098d..fcc030d9f 100644 --- a/oracle/pkg/updater/updater_test.go +++ b/oracle/pkg/updater/updater_test.go @@ -131,6 +131,8 @@ func TestUpdater(t *testing.T) { DecayStartTimeStamp: uint64(startTimestamp.UnixMilli()), DecayEndTimeStamp: uint64(endTimestamp.UnixMilli()), DispatchTimestamp: uint64(midTimestamp.UnixMilli()), + RevertingTxHashes: "", + SharedSecretKey: []byte("shared_secret_key"), } if i%2 == 0 { @@ -173,6 +175,8 @@ func TestUpdater(t *testing.T) { DecayStartTimeStamp: uint64(startTimestamp.UnixMilli()), DecayEndTimeStamp: uint64(endTimestamp.UnixMilli()), DispatchTimestamp: uint64(midTimestamp.UnixMilli()), + RevertingTxHashes: "", + SharedSecretKey: []byte("shared_secret_key"), } encCommitments = append(encCommitments, encCommitment) commitments = append(commitments, commitment) @@ -341,7 +345,6 @@ func TestUpdater(t *testing.T) { t.Fatal("timeout") } } - func TestUpdaterRevertedTxns(t *testing.T) { t.Parallel() @@ -392,6 +395,8 @@ func TestUpdaterRevertedTxns(t *testing.T) { DecayStartTimeStamp: uint64(startTimestamp.UnixMilli()), DecayEndTimeStamp: uint64(endTimestamp.UnixMilli()), DispatchTimestamp: uint64(midTimestamp.UnixMilli()), + RevertingTxHashes: "", + SharedSecretKey: []byte("shared_secret_key"), } if i%2 == 0 { @@ -434,6 +439,8 @@ func TestUpdaterRevertedTxns(t *testing.T) { DecayStartTimeStamp: uint64(startTimestamp.UnixMilli()), DecayEndTimeStamp: uint64(endTimestamp.UnixMilli()), DispatchTimestamp: uint64(midTimestamp.UnixMilli()), + RevertingTxHashes: "", + SharedSecretKey: []byte("shared_secret_key"), } encCommitments = append(encCommitments, encCommitment) commitments = append(commitments, commitment) @@ -609,6 +616,276 @@ func TestUpdaterRevertedTxns(t *testing.T) { } } +func TestUpdaterRevertedTxnsWithRevertingHashes(t *testing.T) { + t.Parallel() + + // timestamp of the First block commitment is X + startTimestamp := time.UnixMilli(1615195200000) + midTimestamp := startTimestamp.Add(time.Duration(2.5 * float64(time.Second))) + endTimestamp := startTimestamp.Add(5 * time.Second) + + key, err := crypto.GenerateKey() + if err != nil { + t.Fatal(err) + } + + builderAddr := common.HexToAddress("0xabcd") + otherBuilderAddr := common.HexToAddress("0xabdc") + + signer := types.NewLondonSigner(big.NewInt(5)) + var txns []*types.Transaction + for i := range 10 { + txns = append(txns, types.MustSignNewTx(key, signer, &types.DynamicFeeTx{ + Nonce: uint64(i + 1), + Gas: 1000000, + Value: big.NewInt(1), + GasTipCap: big.NewInt(500), + GasFeeCap: big.NewInt(500), + })) + } + + encCommitments := make([]preconf.PreconfcommitmentstoreEncryptedCommitmentStored, 0) + commitments := make([]preconf.PreconfcommitmentstoreCommitmentStored, 0) + + for i, txn := range txns { + idxBytes := getIdxBytes(int64(i)) + + encCommitment := preconf.PreconfcommitmentstoreEncryptedCommitmentStored{ + CommitmentIndex: idxBytes, + CommitmentDigest: common.HexToHash(fmt.Sprintf("0x%02d", i)), + CommitmentSignature: []byte("signature"), + DispatchTimestamp: uint64(midTimestamp.UnixMilli()), + } + commitment := preconf.PreconfcommitmentstoreCommitmentStored{ + CommitmentIndex: idxBytes, + TxnHash: strings.TrimPrefix(txn.Hash().Hex(), "0x"), + Bid: big.NewInt(10), + BlockNumber: 5, + CommitmentHash: common.HexToHash(fmt.Sprintf("0x%02d", i)), + CommitmentSignature: []byte("signature"), + DecayStartTimeStamp: uint64(startTimestamp.UnixMilli()), + DecayEndTimeStamp: uint64(endTimestamp.UnixMilli()), + DispatchTimestamp: uint64(midTimestamp.UnixMilli()), + RevertingTxHashes: strings.TrimPrefix(txn.Hash().Hex(), "0x"), + SharedSecretKey: []byte("shared_secret_key"), + } + + if i%2 == 0 { + encCommitment.Commiter = builderAddr + commitment.Commiter = builderAddr + encCommitments = append(encCommitments, encCommitment) + commitments = append(commitments, commitment) + } else { + encCommitment.Commiter = otherBuilderAddr + commitment.Commiter = otherBuilderAddr + encCommitments = append(encCommitments, encCommitment) + commitments = append(commitments, commitment) + } + } + + // constructing bundles + for i := range 10 { + idxBytes := getIdxBytes(int64(i + 10)) + + bundle := strings.TrimPrefix(txns[i].Hash().Hex(), "0x") + for j := i + 1; j < 10; j++ { + bundle += "," + strings.TrimPrefix(txns[j].Hash().Hex(), "0x") + } + + encCommitment := preconf.PreconfcommitmentstoreEncryptedCommitmentStored{ + CommitmentIndex: idxBytes, + Commiter: builderAddr, + CommitmentDigest: common.HexToHash(fmt.Sprintf("0x%02d", i)), + CommitmentSignature: []byte("signature"), + DispatchTimestamp: uint64(midTimestamp.UnixMilli()), + } + commitment := preconf.PreconfcommitmentstoreCommitmentStored{ + CommitmentIndex: idxBytes, + Commiter: builderAddr, + Bid: big.NewInt(10), + TxnHash: bundle, + BlockNumber: 5, + CommitmentHash: common.HexToHash(fmt.Sprintf("0x%02d", i)), + CommitmentSignature: []byte("signature"), + DecayStartTimeStamp: uint64(startTimestamp.UnixMilli()), + DecayEndTimeStamp: uint64(endTimestamp.UnixMilli()), + DispatchTimestamp: uint64(midTimestamp.UnixMilli()), + RevertingTxHashes: bundle, + SharedSecretKey: []byte("shared_secret_key"), + } + encCommitments = append(encCommitments, encCommitment) + commitments = append(commitments, commitment) + } + + register := &testWinnerRegister{ + winners: []testWinner{ + { + blockNum: 5, + winner: updater.Winner{ + Winner: builderAddr.Bytes(), + Window: 1, + }, + }, + }, + settlements: make(chan testSettlement, 1), + encCommit: make(chan testEncryptedCommitment, 1), + } + + l1Client := &testEVMClient{ + blocks: map[int64]*types.Block{ + 5: types.NewBlock(&types.Header{}, txns, nil, nil, NewHasher()), + }, + receipts: make(map[string]*types.Receipt), + } + for _, txn := range txns { + receipt := &types.Receipt{ + Status: types.ReceiptStatusFailed, + TxHash: txn.Hash(), + } + l1Client.receipts[txn.Hash().Hex()] = receipt + } + + pcABI, err := abi.JSON(strings.NewReader(preconf.PreconfcommitmentstoreABI)) + if err != nil { + t.Fatal(err) + } + + btABI, err := abi.JSON(strings.NewReader(blocktracker.BlocktrackerABI)) + if err != nil { + t.Fatal(err) + } + + evtMgr := events.NewListener( + util.NewTestLogger(io.Discard), + &btABI, + &pcABI, + ) + + oracle := &testOracle{ + commitments: make(chan processedCommitment, 1), + } + testBatcher := &testBatcher{ + failedReceipts: make(map[common.Hash]bool), + } + for _, txn := range txns { + testBatcher.failedReceipts[txn.Hash()] = true + } + + updtr, err := updater.NewUpdater( + slog.New(slog.NewTextHandler(io.Discard, nil)), + l1Client, + register, + evtMgr, + oracle, + testBatcher, + ) + if err != nil { + t.Fatal(err) + } + + ctx, cancel := context.WithCancel(context.Background()) + done := updtr.Start(ctx) + + w := blocktracker.BlocktrackerNewWindow{ + Window: big.NewInt(1), + } + publishNewWindow(evtMgr, &btABI, w) + + for _, ec := range encCommitments { + if err := publishEncCommitment(evtMgr, &pcABI, ec); err != nil { + t.Fatal(err) + } + + select { + case <-time.After(5 * time.Second): + t.Fatal("timeout") + case enc := <-register.encCommit: + if !bytes.Equal(enc.commitmentIdx, ec.CommitmentIndex[:]) { + t.Fatal("wrong commitment index") + } + if !bytes.Equal(enc.committer, ec.Commiter.Bytes()) { + t.Fatal("wrong committer") + } + if !bytes.Equal(enc.commitmentHash, ec.CommitmentDigest[:]) { + t.Fatal("wrong commitment hash") + } + if !bytes.Equal(enc.commitmentSignature, ec.CommitmentSignature) { + t.Fatal("wrong commitment signature") + } + if enc.dispatchTimestamp != ec.DispatchTimestamp { + t.Fatal("wrong dispatch timestamp") + } + } + } + + for _, c := range commitments { + if err := publishCommitment(evtMgr, &pcABI, c); err != nil { + t.Fatal(err) + } + + if c.Commiter.Cmp(otherBuilderAddr) == 0 { + continue + } + + select { + case <-time.After(5 * time.Second): + t.Fatal("timeout") + case commitment := <-oracle.commitments: + if !bytes.Equal(commitment.commitmentIdx[:], c.CommitmentIndex[:]) { + t.Fatal("wrong commitment index") + } + if commitment.blockNum.Cmp(big.NewInt(5)) != 0 { + t.Fatal("wrong block number") + } + if commitment.builder != c.Commiter { + t.Fatal("wrong builder") + } + if commitment.isSlash { + t.Fatal("wrong isSlash") + } + if commitment.residualDecay.Cmp(big.NewInt(50)) != 0 { + t.Fatal("wrong residual decay") + } + } + + select { + case <-time.After(5 * time.Second): + t.Fatal("timeout") + case settlement := <-register.settlements: + if !bytes.Equal(settlement.commitmentIdx, c.CommitmentIndex[:]) { + t.Fatal("wrong commitment index") + } + if settlement.txHash != c.TxnHash { + t.Fatal("wrong txn hash") + } + if settlement.blockNum != 5 { + t.Fatal("wrong block number") + } + if !bytes.Equal(settlement.builder, c.Commiter.Bytes()) { + t.Fatal("wrong builder") + } + if settlement.amount.Uint64() != 10 { + t.Fatal("wrong amount") + } + if settlement.settlementType != updater.SettlementTypeReward { + t.Fatal("wrong settlement type") + } + if settlement.decayPercentage != 50 { + t.Fatal("wrong decay percentage") + } + if settlement.window != 1 { + t.Fatal("wrong window") + } + } + } + + cancel() + select { + case <-done: + case <-time.After(5 * time.Second): + t.Fatal("timeout") + } +} func TestUpdaterBundlesFailure(t *testing.T) { t.Parallel() @@ -657,6 +934,8 @@ func TestUpdaterBundlesFailure(t *testing.T) { DecayStartTimeStamp: uint64(startTimestamp.UnixMilli()), DecayEndTimeStamp: uint64(endTimestamp.UnixMilli()), DispatchTimestamp: uint64(midTimestamp.UnixMilli()), + RevertingTxHashes: "", + SharedSecretKey: []byte("shared_secret_key"), } commitments = append(commitments, commitment) @@ -841,6 +1120,7 @@ func TestUpdaterIgnoreCommitments(t *testing.T) { Commiter: builderAddr, Bid: big.NewInt(10), TxnHash: strings.TrimPrefix(txn.Hash().Hex(), "0x"), + RevertingTxHashes: "", BlockNumber: blockNum, CommitmentHash: common.HexToHash(fmt.Sprintf("0x%02d", i)), CommitmentSignature: []byte("signature"), @@ -1203,6 +1483,7 @@ func publishCommitment( c.DecayStartTimeStamp, c.DecayEndTimeStamp, c.TxnHash, + c.RevertingTxHashes, c.CommitmentHash, c.BidSignature, c.CommitmentSignature, diff --git a/p2p/gen/go/bidderapi/v1/bidderapi.pb.go b/p2p/gen/go/bidderapi/v1/bidderapi.pb.go index 796b344da..582cb545c 100644 --- a/p2p/gen/go/bidderapi/v1/bidderapi.pb.go +++ b/p2p/gen/go/bidderapi/v1/bidderapi.pb.go @@ -339,6 +339,7 @@ type Bid struct { BlockNumber int64 `protobuf:"varint,3,opt,name=block_number,json=blockNumber,proto3" json:"block_number,omitempty"` DecayStartTimestamp int64 `protobuf:"varint,4,opt,name=decay_start_timestamp,json=decayStartTimestamp,proto3" json:"decay_start_timestamp,omitempty"` DecayEndTimestamp int64 `protobuf:"varint,5,opt,name=decay_end_timestamp,json=decayEndTimestamp,proto3" json:"decay_end_timestamp,omitempty"` + RevertingTxHashes []string `protobuf:"bytes,6,rep,name=reverting_tx_hashes,json=revertingTxHashes,proto3" json:"reverting_tx_hashes,omitempty"` } func (x *Bid) Reset() { @@ -408,6 +409,13 @@ func (x *Bid) GetDecayEndTimestamp() int64 { return 0 } +func (x *Bid) GetRevertingTxHashes() []string { + if x != nil { + return x.RevertingTxHashes + } + return nil +} + type Commitment struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -424,6 +432,7 @@ type Commitment struct { DecayStartTimestamp int64 `protobuf:"varint,9,opt,name=decay_start_timestamp,json=decayStartTimestamp,proto3" json:"decay_start_timestamp,omitempty"` DecayEndTimestamp int64 `protobuf:"varint,10,opt,name=decay_end_timestamp,json=decayEndTimestamp,proto3" json:"decay_end_timestamp,omitempty"` DispatchTimestamp int64 `protobuf:"varint,11,opt,name=dispatch_timestamp,json=dispatchTimestamp,proto3" json:"dispatch_timestamp,omitempty"` + RevertingTxHashes []string `protobuf:"bytes,12,rep,name=reverting_tx_hashes,json=revertingTxHashes,proto3" json:"reverting_tx_hashes,omitempty"` } func (x *Commitment) Reset() { @@ -535,6 +544,13 @@ func (x *Commitment) GetDispatchTimestamp() int64 { return 0 } +func (x *Commitment) GetRevertingTxHashes() []string { + if x != nil { + return x.RevertingTxHashes + } + return nil +} + var File_bidderapi_v1_bidderapi_proto protoreflect.FileDescriptor var file_bidderapi_v1_bidderapi_proto_rawDesc = []byte{ @@ -678,7 +694,7 @@ var file_bidderapi_v1_bidderapi_proto_rawDesc = []byte{ 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x3a, 0x20, 0x22, 0x31, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x22, 0x2c, 0x20, 0x22, 0x77, 0x69, 0x6e, 0x64, 0x6f, 0x77, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x22, 0x3a, - 0x20, 0x31, 0x20, 0x7d, 0x22, 0xa6, 0x0b, 0x0a, 0x03, 0x42, 0x69, 0x64, 0x12, 0xa3, 0x02, 0x0a, + 0x20, 0x31, 0x20, 0x7d, 0x22, 0xb3, 0x0d, 0x0a, 0x03, 0x42, 0x69, 0x64, 0x12, 0xa3, 0x02, 0x0a, 0x09, 0x74, 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x42, 0x85, 0x02, 0x92, 0x41, 0x78, 0x32, 0x64, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, 0x74, @@ -747,167 +763,191 @@ var file_bidderapi_v1_bidderapi_proto_rawDesc = []byte{ 0x6d, 0x70, 0x20, 0x6d, 0x75, 0x73, 0x74, 0x20, 0x62, 0x65, 0x20, 0x61, 0x20, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x67, 0x65, 0x72, 0x2e, 0x1a, 0x0e, 0x75, 0x69, 0x6e, 0x74, 0x28, 0x74, 0x68, 0x69, 0x73, 0x29, 0x20, 0x3e, 0x20, 0x30, 0x52, 0x11, 0x64, 0x65, 0x63, - 0x61, 0x79, 0x45, 0x6e, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x3a, 0xcc, - 0x02, 0x92, 0x41, 0xc8, 0x02, 0x0a, 0x73, 0x2a, 0x0b, 0x42, 0x69, 0x64, 0x20, 0x6d, 0x65, 0x73, - 0x73, 0x61, 0x67, 0x65, 0x32, 0x40, 0x55, 0x6e, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x20, 0x62, - 0x69, 0x64, 0x20, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20, - 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, - 0x69, 0x64, 0x64, 0x65, 0x72, 0x20, 0x6d, 0x65, 0x76, 0x2d, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x20, 0x6e, 0x6f, 0x64, 0x65, 0x2e, 0xd2, 0x01, 0x09, 0x74, 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, - 0x65, 0x73, 0xd2, 0x01, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0xd2, 0x01, 0x0c, 0x62, 0x6c, - 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x32, 0xd0, 0x01, 0x7b, 0x22, 0x74, - 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x22, 0x3a, 0x20, 0x5b, 0x22, 0x66, 0x65, 0x34, - 0x63, 0x62, 0x34, 0x37, 0x64, 0x62, 0x33, 0x36, 0x33, 0x30, 0x35, 0x35, 0x31, 0x62, 0x65, 0x65, - 0x64, 0x66, 0x62, 0x64, 0x30, 0x32, 0x61, 0x37, 0x31, 0x65, 0x63, 0x63, 0x36, 0x39, 0x66, 0x64, - 0x35, 0x39, 0x37, 0x35, 0x38, 0x65, 0x32, 0x62, 0x61, 0x36, 0x39, 0x39, 0x36, 0x30, 0x36, 0x65, - 0x32, 0x64, 0x35, 0x63, 0x37, 0x34, 0x32, 0x38, 0x34, 0x66, 0x66, 0x61, 0x37, 0x22, 0x2c, 0x20, - 0x22, 0x37, 0x31, 0x63, 0x31, 0x33, 0x34, 0x38, 0x66, 0x32, 0x64, 0x37, 0x66, 0x66, 0x37, 0x65, - 0x38, 0x31, 0x34, 0x66, 0x39, 0x63, 0x33, 0x36, 0x31, 0x37, 0x39, 0x38, 0x33, 0x37, 0x30, 0x33, - 0x34, 0x33, 0x35, 0x65, 0x61, 0x37, 0x34, 0x34, 0x36, 0x64, 0x65, 0x34, 0x32, 0x30, 0x61, 0x65, - 0x61, 0x63, 0x34, 0x38, 0x38, 0x62, 0x66, 0x31, 0x64, 0x65, 0x33, 0x35, 0x37, 0x33, 0x37, 0x65, - 0x38, 0x22, 0x5d, 0x2c, 0x20, 0x22, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x3a, 0x20, 0x22, - 0x31, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, - 0x30, 0x30, 0x30, 0x22, 0x2c, 0x20, 0x22, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, - 0x62, 0x65, 0x72, 0x22, 0x3a, 0x20, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x7d, 0x22, 0xdc, 0x0a, - 0x0a, 0x0a, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x95, 0x01, 0x0a, - 0x09, 0x74, 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, - 0x42, 0x78, 0x92, 0x41, 0x75, 0x32, 0x61, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, - 0x67, 0x20, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, - 0x65, 0x20, 0x68, 0x61, 0x73, 0x68, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x74, 0x72, - 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x74, - 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x20, 0x77, 0x61, 0x6e, 0x74, 0x73, 0x20, - 0x74, 0x6f, 0x20, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x20, 0x69, 0x6e, 0x20, 0x74, 0x68, - 0x65, 0x20, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x2e, 0x8a, 0x01, 0x0f, 0x5b, 0x61, 0x2d, 0x66, 0x41, - 0x2d, 0x46, 0x30, 0x2d, 0x39, 0x5d, 0x7b, 0x36, 0x34, 0x7d, 0x52, 0x08, 0x74, 0x78, 0x48, 0x61, - 0x73, 0x68, 0x65, 0x73, 0x12, 0x8f, 0x01, 0x0a, 0x0a, 0x62, 0x69, 0x64, 0x5f, 0x61, 0x6d, 0x6f, - 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x70, 0x92, 0x41, 0x6d, 0x32, 0x6b, - 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x20, 0x6f, 0x66, 0x20, 0x45, 0x54, 0x48, 0x20, 0x74, 0x68, - 0x61, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x20, 0x68, 0x61, - 0x73, 0x20, 0x61, 0x67, 0x72, 0x65, 0x65, 0x64, 0x20, 0x74, 0x6f, 0x20, 0x70, 0x61, 0x79, 0x20, - 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x20, - 0x66, 0x6f, 0x72, 0x20, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x74, 0x68, - 0x65, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x69, 0x6e, - 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x2e, 0x52, 0x09, 0x62, 0x69, 0x64, - 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x6d, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, - 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x42, 0x4a, 0x92, 0x41, - 0x47, 0x32, 0x45, 0x4d, 0x61, 0x78, 0x20, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x20, 0x6e, 0x75, 0x6d, - 0x62, 0x65, 0x72, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, - 0x64, 0x65, 0x72, 0x20, 0x77, 0x61, 0x6e, 0x74, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x69, 0x6e, 0x63, - 0x6c, 0x75, 0x64, 0x65, 0x20, 0x74, 0x68, 0x65, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x69, 0x6e, 0x2e, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, - 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x7b, 0x0a, 0x13, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, - 0x64, 0x5f, 0x62, 0x69, 0x64, 0x5f, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x09, 0x42, 0x4b, 0x92, 0x41, 0x48, 0x32, 0x46, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, - 0x69, 0x6e, 0x67, 0x20, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, - 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, - 0x64, 0x20, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x20, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x64, - 0x20, 0x62, 0x79, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x2e, 0x52, - 0x11, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x64, 0x42, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, - 0x73, 0x74, 0x12, 0x7d, 0x0a, 0x16, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x64, 0x5f, 0x62, - 0x69, 0x64, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x05, 0x20, 0x01, - 0x28, 0x09, 0x42, 0x47, 0x92, 0x41, 0x44, 0x32, 0x42, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, - 0x69, 0x6e, 0x67, 0x20, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, - 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, - 0x20, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x73, 0x65, 0x6e, - 0x74, 0x20, 0x74, 0x68, 0x69, 0x73, 0x20, 0x62, 0x69, 0x64, 0x2e, 0x52, 0x14, 0x72, 0x65, 0x63, - 0x65, 0x69, 0x76, 0x65, 0x64, 0x42, 0x69, 0x64, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x12, 0x62, 0x0a, 0x11, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x5f, - 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x42, 0x35, 0x92, 0x41, - 0x32, 0x32, 0x30, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x65, 0x6e, - 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, - 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, - 0x6e, 0x74, 0x2e, 0x52, 0x10, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x44, - 0x69, 0x67, 0x65, 0x73, 0x74, 0x12, 0x9e, 0x01, 0x0a, 0x14, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x09, 0x42, 0x6b, 0x92, 0x41, 0x68, 0x32, 0x66, 0x48, 0x65, 0x78, 0x20, 0x73, - 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, - 0x66, 0x20, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x74, - 0x68, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x73, 0x69, - 0x67, 0x6e, 0x65, 0x64, 0x20, 0x62, 0x79, 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x6f, 0x76, - 0x69, 0x64, 0x65, 0x72, 0x20, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x20, - 0x74, 0x68, 0x69, 0x73, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, - 0x2e, 0x52, 0x13, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x53, 0x69, 0x67, - 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x88, 0x01, 0x0a, 0x10, 0x70, 0x72, 0x6f, 0x76, 0x69, - 0x64, 0x65, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, - 0x09, 0x42, 0x5d, 0x92, 0x41, 0x5a, 0x32, 0x58, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, 0x69, - 0x6e, 0x67, 0x20, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, 0x74, - 0x68, 0x65, 0x20, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, - 0x65, 0x20, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, - 0x73, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x2e, - 0x52, 0x0f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, - 0x73, 0x12, 0x64, 0x0a, 0x15, 0x64, 0x65, 0x63, 0x61, 0x79, 0x5f, 0x73, 0x74, 0x61, 0x72, 0x74, - 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, - 0x42, 0x30, 0x92, 0x41, 0x2d, 0x32, 0x2b, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, - 0x20, 0x61, 0x74, 0x20, 0x77, 0x68, 0x69, 0x63, 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, - 0x64, 0x20, 0x73, 0x74, 0x61, 0x72, 0x74, 0x73, 0x20, 0x64, 0x65, 0x63, 0x61, 0x79, 0x69, 0x6e, - 0x67, 0x2e, 0x52, 0x13, 0x64, 0x65, 0x63, 0x61, 0x79, 0x53, 0x74, 0x61, 0x72, 0x74, 0x54, 0x69, - 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x5e, 0x0a, 0x13, 0x64, 0x65, 0x63, 0x61, 0x79, - 0x5f, 0x65, 0x6e, 0x64, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x0a, - 0x20, 0x01, 0x28, 0x03, 0x42, 0x2e, 0x92, 0x41, 0x2b, 0x32, 0x29, 0x54, 0x69, 0x6d, 0x65, 0x73, - 0x74, 0x61, 0x6d, 0x70, 0x20, 0x61, 0x74, 0x20, 0x77, 0x68, 0x69, 0x63, 0x68, 0x20, 0x74, 0x68, - 0x65, 0x20, 0x62, 0x69, 0x64, 0x20, 0x65, 0x6e, 0x64, 0x73, 0x20, 0x64, 0x65, 0x63, 0x61, 0x79, - 0x69, 0x6e, 0x67, 0x2e, 0x52, 0x11, 0x64, 0x65, 0x63, 0x61, 0x79, 0x45, 0x6e, 0x64, 0x54, 0x69, - 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x63, 0x0a, 0x12, 0x64, 0x69, 0x73, 0x70, 0x61, - 0x74, 0x63, 0x68, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x0b, 0x20, - 0x01, 0x28, 0x03, 0x42, 0x34, 0x92, 0x41, 0x31, 0x32, 0x2f, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, - 0x61, 0x6d, 0x70, 0x20, 0x61, 0x74, 0x20, 0x77, 0x68, 0x69, 0x63, 0x68, 0x20, 0x74, 0x68, 0x65, - 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x69, 0x73, 0x20, 0x70, - 0x75, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x65, 0x64, 0x2e, 0x52, 0x11, 0x64, 0x69, 0x73, 0x70, 0x61, - 0x74, 0x63, 0x68, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x32, 0x90, 0x04, 0x0a, - 0x06, 0x42, 0x69, 0x64, 0x64, 0x65, 0x72, 0x12, 0x53, 0x0a, 0x07, 0x53, 0x65, 0x6e, 0x64, 0x42, - 0x69, 0x64, 0x12, 0x11, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, - 0x31, 0x2e, 0x42, 0x69, 0x64, 0x1a, 0x18, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, - 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x22, - 0x19, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x13, 0x3a, 0x01, 0x2a, 0x22, 0x0e, 0x2f, 0x76, 0x31, 0x2f, - 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x2f, 0x62, 0x69, 0x64, 0x30, 0x01, 0x12, 0x6b, 0x0a, 0x07, - 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x1c, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, - 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, - 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x22, 0x1b, 0x2f, 0x76, - 0x31, 0x2f, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x2f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, - 0x2f, 0x7b, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x7d, 0x12, 0x6c, 0x0a, 0x0a, 0x47, 0x65, 0x74, - 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x1f, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, - 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, - 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, - 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x18, 0x12, - 0x16, 0x2f, 0x76, 0x31, 0x2f, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x2f, 0x67, 0x65, 0x74, 0x5f, - 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x6e, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4d, 0x69, - 0x6e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x1a, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, - 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x4d, 0x65, 0x73, - 0x73, 0x61, 0x67, 0x65, 0x1a, 0x1d, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, - 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x31, - 0x2f, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x2f, 0x67, 0x65, 0x74, 0x5f, 0x6d, 0x69, 0x6e, 0x5f, - 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x66, 0x0a, 0x08, 0x57, 0x69, 0x74, 0x68, 0x64, - 0x72, 0x61, 0x77, 0x12, 0x1d, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, - 0x76, 0x31, 0x2e, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, - 0x31, 0x2e, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x1b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x15, 0x22, 0x13, 0x2f, 0x76, 0x31, 0x2f, - 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x2f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x42, - 0xaa, 0x02, 0x92, 0x41, 0x72, 0x12, 0x70, 0x0a, 0x0a, 0x42, 0x69, 0x64, 0x64, 0x65, 0x72, 0x20, - 0x41, 0x50, 0x49, 0x2a, 0x55, 0x0a, 0x1b, 0x42, 0x75, 0x73, 0x69, 0x6e, 0x65, 0x73, 0x73, 0x20, - 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x4c, 0x69, 0x63, 0x65, 0x6e, 0x73, 0x65, 0x20, 0x31, - 0x2e, 0x31, 0x12, 0x36, 0x68, 0x74, 0x74, 0x70, 0x73, 0x3a, 0x2f, 0x2f, 0x67, 0x69, 0x74, 0x68, - 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x65, 0x76, 0x2f, 0x6d, 0x65, - 0x76, 0x2d, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x2f, 0x6d, 0x61, - 0x69, 0x6e, 0x2f, 0x4c, 0x49, 0x43, 0x45, 0x4e, 0x53, 0x45, 0x32, 0x0b, 0x31, 0x2e, 0x30, 0x2e, - 0x30, 0x2d, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x62, 0x69, 0x64, - 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x42, 0x0e, 0x42, 0x69, 0x64, 0x64, 0x65, - 0x72, 0x61, 0x70, 0x69, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x40, 0x67, 0x69, 0x74, - 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x65, 0x76, 0x2f, 0x6d, - 0x65, 0x76, 0x2d, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x70, 0x32, 0x70, 0x2f, 0x67, 0x65, - 0x6e, 0x2f, 0x67, 0x6f, 0x2f, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2f, 0x76, - 0x31, 0x3b, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x76, 0x31, 0xa2, 0x02, 0x03, - 0x42, 0x58, 0x58, 0xaa, 0x02, 0x0c, 0x42, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, - 0x56, 0x31, 0xca, 0x02, 0x0c, 0x42, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x5c, 0x56, - 0x31, 0xe2, 0x02, 0x18, 0x42, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x5c, 0x56, 0x31, - 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0d, 0x42, - 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x33, + 0x61, 0x79, 0x45, 0x6e, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x8a, + 0x02, 0x0a, 0x13, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x74, 0x78, 0x5f, + 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x09, 0x42, 0xd9, 0x01, 0x92, + 0x41, 0x49, 0x32, 0x47, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x20, 0x61, 0x72, 0x72, + 0x61, 0x79, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x78, 0x20, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x20, + 0x74, 0x68, 0x61, 0x74, 0x20, 0x61, 0x72, 0x65, 0x20, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x65, 0x64, + 0x20, 0x74, 0x6f, 0x20, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x20, 0x6f, 0x72, 0x20, 0x62, 0x65, + 0x20, 0x64, 0x69, 0x73, 0x63, 0x61, 0x72, 0x64, 0x65, 0x64, 0x2e, 0xba, 0x48, 0x89, 0x01, 0xba, + 0x01, 0x85, 0x01, 0x0a, 0x13, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x74, + 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x12, 0x41, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, + 0x69, 0x6e, 0x67, 0x5f, 0x74, 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x20, 0x6d, 0x75, + 0x73, 0x74, 0x20, 0x62, 0x65, 0x20, 0x61, 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x6f, + 0x66, 0x20, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, + 0x69, 0x6f, 0x6e, 0x20, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x2e, 0x1a, 0x2b, 0x74, 0x68, 0x69, + 0x73, 0x2e, 0x61, 0x6c, 0x6c, 0x28, 0x72, 0x2c, 0x20, 0x72, 0x2e, 0x6d, 0x61, 0x74, 0x63, 0x68, + 0x65, 0x73, 0x28, 0x27, 0x5e, 0x5b, 0x61, 0x2d, 0x66, 0x41, 0x2d, 0x46, 0x30, 0x2d, 0x39, 0x5d, + 0x7b, 0x36, 0x34, 0x7d, 0x24, 0x27, 0x29, 0x29, 0x52, 0x11, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, + 0x69, 0x6e, 0x67, 0x54, 0x78, 0x48, 0x61, 0x73, 0x68, 0x65, 0x73, 0x3a, 0xcc, 0x02, 0x92, 0x41, + 0xc8, 0x02, 0x0a, 0x73, 0x2a, 0x0b, 0x42, 0x69, 0x64, 0x20, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, + 0x65, 0x32, 0x40, 0x55, 0x6e, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x20, 0x62, 0x69, 0x64, 0x20, + 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x62, 0x69, 0x64, + 0x64, 0x65, 0x72, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x64, + 0x65, 0x72, 0x20, 0x6d, 0x65, 0x76, 0x2d, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x20, 0x6e, 0x6f, + 0x64, 0x65, 0x2e, 0xd2, 0x01, 0x09, 0x74, 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0xd2, + 0x01, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0xd2, 0x01, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, + 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x32, 0xd0, 0x01, 0x7b, 0x22, 0x74, 0x78, 0x5f, 0x68, + 0x61, 0x73, 0x68, 0x65, 0x73, 0x22, 0x3a, 0x20, 0x5b, 0x22, 0x66, 0x65, 0x34, 0x63, 0x62, 0x34, + 0x37, 0x64, 0x62, 0x33, 0x36, 0x33, 0x30, 0x35, 0x35, 0x31, 0x62, 0x65, 0x65, 0x64, 0x66, 0x62, + 0x64, 0x30, 0x32, 0x61, 0x37, 0x31, 0x65, 0x63, 0x63, 0x36, 0x39, 0x66, 0x64, 0x35, 0x39, 0x37, + 0x35, 0x38, 0x65, 0x32, 0x62, 0x61, 0x36, 0x39, 0x39, 0x36, 0x30, 0x36, 0x65, 0x32, 0x64, 0x35, + 0x63, 0x37, 0x34, 0x32, 0x38, 0x34, 0x66, 0x66, 0x61, 0x37, 0x22, 0x2c, 0x20, 0x22, 0x37, 0x31, + 0x63, 0x31, 0x33, 0x34, 0x38, 0x66, 0x32, 0x64, 0x37, 0x66, 0x66, 0x37, 0x65, 0x38, 0x31, 0x34, + 0x66, 0x39, 0x63, 0x33, 0x36, 0x31, 0x37, 0x39, 0x38, 0x33, 0x37, 0x30, 0x33, 0x34, 0x33, 0x35, + 0x65, 0x61, 0x37, 0x34, 0x34, 0x36, 0x64, 0x65, 0x34, 0x32, 0x30, 0x61, 0x65, 0x61, 0x63, 0x34, + 0x38, 0x38, 0x62, 0x66, 0x31, 0x64, 0x65, 0x33, 0x35, 0x37, 0x33, 0x37, 0x65, 0x38, 0x22, 0x5d, + 0x2c, 0x20, 0x22, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x3a, 0x20, 0x22, 0x31, 0x30, 0x30, + 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, + 0x22, 0x2c, 0x20, 0x22, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, + 0x22, 0x3a, 0x20, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x7d, 0x22, 0xda, 0x0b, 0x0a, 0x0a, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x95, 0x01, 0x0a, 0x09, 0x74, 0x78, + 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x42, 0x78, 0x92, + 0x41, 0x75, 0x32, 0x61, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x65, + 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x68, + 0x61, 0x73, 0x68, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, + 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, + 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x20, 0x77, 0x61, 0x6e, 0x74, 0x73, 0x20, 0x74, 0x6f, 0x20, + 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x20, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, + 0x6c, 0x6f, 0x63, 0x6b, 0x2e, 0x8a, 0x01, 0x0f, 0x5b, 0x61, 0x2d, 0x66, 0x41, 0x2d, 0x46, 0x30, + 0x2d, 0x39, 0x5d, 0x7b, 0x36, 0x34, 0x7d, 0x52, 0x08, 0x74, 0x78, 0x48, 0x61, 0x73, 0x68, 0x65, + 0x73, 0x12, 0x8f, 0x01, 0x0a, 0x0a, 0x62, 0x69, 0x64, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x70, 0x92, 0x41, 0x6d, 0x32, 0x6b, 0x41, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x20, 0x6f, 0x66, 0x20, 0x45, 0x54, 0x48, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, + 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x20, 0x68, 0x61, 0x73, 0x20, 0x61, + 0x67, 0x72, 0x65, 0x65, 0x64, 0x20, 0x74, 0x6f, 0x20, 0x70, 0x61, 0x79, 0x20, 0x74, 0x6f, 0x20, + 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x20, 0x66, 0x6f, 0x72, + 0x20, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x74, 0x68, 0x65, 0x20, 0x74, + 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x69, 0x6e, 0x20, 0x74, 0x68, + 0x65, 0x20, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x2e, 0x52, 0x09, 0x62, 0x69, 0x64, 0x41, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x12, 0x6d, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, + 0x62, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x42, 0x4a, 0x92, 0x41, 0x47, 0x32, 0x45, + 0x4d, 0x61, 0x78, 0x20, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x20, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, + 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, + 0x20, 0x77, 0x61, 0x6e, 0x74, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, + 0x65, 0x20, 0x74, 0x68, 0x65, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, + 0x6e, 0x20, 0x69, 0x6e, 0x2e, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, + 0x65, 0x72, 0x12, 0x7b, 0x0a, 0x13, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x64, 0x5f, 0x62, + 0x69, 0x64, 0x5f, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x4b, 0x92, 0x41, 0x48, 0x32, 0x46, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, + 0x20, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, 0x64, 0x69, 0x67, + 0x65, 0x73, 0x74, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x20, 0x6d, + 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x20, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x20, 0x62, 0x79, + 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x2e, 0x52, 0x11, 0x72, 0x65, + 0x63, 0x65, 0x69, 0x76, 0x65, 0x64, 0x42, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x12, + 0x7d, 0x0a, 0x16, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x64, 0x5f, 0x62, 0x69, 0x64, 0x5f, + 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x47, 0x92, 0x41, 0x44, 0x32, 0x42, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, + 0x20, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, 0x73, 0x69, 0x67, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, + 0x64, 0x64, 0x65, 0x72, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x73, 0x65, 0x6e, 0x74, 0x20, 0x74, + 0x68, 0x69, 0x73, 0x20, 0x62, 0x69, 0x64, 0x2e, 0x52, 0x14, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, + 0x65, 0x64, 0x42, 0x69, 0x64, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x62, + 0x0a, 0x11, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x64, 0x69, 0x67, + 0x65, 0x73, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x42, 0x35, 0x92, 0x41, 0x32, 0x32, 0x30, + 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x65, 0x6e, 0x63, 0x6f, 0x64, + 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x20, 0x6f, 0x66, + 0x20, 0x74, 0x68, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x2e, + 0x52, 0x10, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x44, 0x69, 0x67, 0x65, + 0x73, 0x74, 0x12, 0x9e, 0x01, 0x0a, 0x14, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, + 0x74, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x6b, 0x92, 0x41, 0x68, 0x32, 0x66, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, 0x69, + 0x6e, 0x67, 0x20, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, 0x73, + 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, + 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x73, 0x69, 0x67, 0x6e, 0x65, + 0x64, 0x20, 0x62, 0x79, 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, + 0x72, 0x20, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x20, 0x74, 0x68, 0x69, + 0x73, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x13, + 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, + 0x75, 0x72, 0x65, 0x12, 0x88, 0x01, 0x0a, 0x10, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, + 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x42, 0x5d, + 0x92, 0x41, 0x5a, 0x32, 0x58, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20, + 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, + 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, + 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x73, 0x69, 0x67, + 0x6e, 0x65, 0x64, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, + 0x6e, 0x74, 0x20, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x2e, 0x52, 0x0f, 0x70, + 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x64, + 0x0a, 0x15, 0x64, 0x65, 0x63, 0x61, 0x79, 0x5f, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x69, + 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x42, 0x30, 0x92, + 0x41, 0x2d, 0x32, 0x2b, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x20, 0x61, 0x74, + 0x20, 0x77, 0x68, 0x69, 0x63, 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x20, 0x73, + 0x74, 0x61, 0x72, 0x74, 0x73, 0x20, 0x64, 0x65, 0x63, 0x61, 0x79, 0x69, 0x6e, 0x67, 0x2e, 0x52, + 0x13, 0x64, 0x65, 0x63, 0x61, 0x79, 0x53, 0x74, 0x61, 0x72, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x73, + 0x74, 0x61, 0x6d, 0x70, 0x12, 0x5e, 0x0a, 0x13, 0x64, 0x65, 0x63, 0x61, 0x79, 0x5f, 0x65, 0x6e, + 0x64, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x0a, 0x20, 0x01, 0x28, + 0x03, 0x42, 0x2e, 0x92, 0x41, 0x2b, 0x32, 0x29, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, + 0x70, 0x20, 0x61, 0x74, 0x20, 0x77, 0x68, 0x69, 0x63, 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, + 0x69, 0x64, 0x20, 0x65, 0x6e, 0x64, 0x73, 0x20, 0x64, 0x65, 0x63, 0x61, 0x79, 0x69, 0x6e, 0x67, + 0x2e, 0x52, 0x11, 0x64, 0x65, 0x63, 0x61, 0x79, 0x45, 0x6e, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x73, + 0x74, 0x61, 0x6d, 0x70, 0x12, 0x63, 0x0a, 0x12, 0x64, 0x69, 0x73, 0x70, 0x61, 0x74, 0x63, 0x68, + 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x03, + 0x42, 0x34, 0x92, 0x41, 0x31, 0x32, 0x2f, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, + 0x20, 0x61, 0x74, 0x20, 0x77, 0x68, 0x69, 0x63, 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x69, 0x73, 0x20, 0x70, 0x75, 0x62, 0x6c, + 0x69, 0x73, 0x68, 0x65, 0x64, 0x2e, 0x52, 0x11, 0x64, 0x69, 0x73, 0x70, 0x61, 0x74, 0x63, 0x68, + 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x7c, 0x0a, 0x13, 0x72, 0x65, 0x76, + 0x65, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x74, 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, + 0x18, 0x0c, 0x20, 0x03, 0x28, 0x09, 0x42, 0x4c, 0x92, 0x41, 0x49, 0x32, 0x47, 0x4f, 0x70, 0x74, + 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x6f, 0x66, 0x20, 0x74, + 0x78, 0x20, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x61, 0x72, + 0x65, 0x20, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x65, 0x64, 0x20, 0x74, 0x6f, 0x20, 0x72, 0x65, 0x76, + 0x65, 0x72, 0x74, 0x20, 0x6f, 0x72, 0x20, 0x62, 0x65, 0x20, 0x64, 0x69, 0x73, 0x63, 0x61, 0x72, + 0x64, 0x65, 0x64, 0x2e, 0x52, 0x11, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x54, + 0x78, 0x48, 0x61, 0x73, 0x68, 0x65, 0x73, 0x32, 0x90, 0x04, 0x0a, 0x06, 0x42, 0x69, 0x64, 0x64, + 0x65, 0x72, 0x12, 0x53, 0x0a, 0x07, 0x53, 0x65, 0x6e, 0x64, 0x42, 0x69, 0x64, 0x12, 0x11, 0x2e, + 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x69, 0x64, + 0x1a, 0x18, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x19, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x13, 0x3a, 0x01, 0x2a, 0x22, 0x0e, 0x2f, 0x76, 0x31, 0x2f, 0x62, 0x69, 0x64, 0x64, 0x65, + 0x72, 0x2f, 0x62, 0x69, 0x64, 0x30, 0x01, 0x12, 0x6b, 0x0a, 0x07, 0x44, 0x65, 0x70, 0x6f, 0x73, + 0x69, 0x74, 0x12, 0x1c, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, + 0x31, 0x2e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x1d, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, + 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x22, 0x1b, 0x2f, 0x76, 0x31, 0x2f, 0x62, 0x69, 0x64, + 0x64, 0x65, 0x72, 0x2f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x7d, 0x12, 0x6c, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x44, 0x65, 0x70, 0x6f, 0x73, + 0x69, 0x74, 0x12, 0x1f, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, + 0x76, 0x31, 0x2e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x1e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x18, 0x12, 0x16, 0x2f, 0x76, 0x31, 0x2f, + 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x2f, 0x67, 0x65, 0x74, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, + 0x69, 0x74, 0x12, 0x6e, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4d, 0x69, 0x6e, 0x44, 0x65, 0x70, 0x6f, + 0x73, 0x69, 0x74, 0x12, 0x1a, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, + 0x76, 0x31, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, + 0x1d, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, + 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x31, 0x2f, 0x62, 0x69, 0x64, 0x64, + 0x65, 0x72, 0x2f, 0x67, 0x65, 0x74, 0x5f, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, + 0x69, 0x74, 0x12, 0x66, 0x0a, 0x08, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x12, 0x1d, + 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x69, + 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, + 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x69, 0x74, + 0x68, 0x64, 0x72, 0x61, 0x77, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1b, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x15, 0x22, 0x13, 0x2f, 0x76, 0x31, 0x2f, 0x62, 0x69, 0x64, 0x64, 0x65, + 0x72, 0x2f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x42, 0xaa, 0x02, 0x92, 0x41, 0x72, + 0x12, 0x70, 0x0a, 0x0a, 0x42, 0x69, 0x64, 0x64, 0x65, 0x72, 0x20, 0x41, 0x50, 0x49, 0x2a, 0x55, + 0x0a, 0x1b, 0x42, 0x75, 0x73, 0x69, 0x6e, 0x65, 0x73, 0x73, 0x20, 0x53, 0x6f, 0x75, 0x72, 0x63, + 0x65, 0x20, 0x4c, 0x69, 0x63, 0x65, 0x6e, 0x73, 0x65, 0x20, 0x31, 0x2e, 0x31, 0x12, 0x36, 0x68, + 0x74, 0x74, 0x70, 0x73, 0x3a, 0x2f, 0x2f, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, + 0x6d, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x65, 0x76, 0x2f, 0x6d, 0x65, 0x76, 0x2d, 0x63, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x2f, 0x6d, 0x61, 0x69, 0x6e, 0x2f, 0x4c, 0x49, + 0x43, 0x45, 0x4e, 0x53, 0x45, 0x32, 0x0b, 0x31, 0x2e, 0x30, 0x2e, 0x30, 0x2d, 0x61, 0x6c, 0x70, + 0x68, 0x61, 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, + 0x69, 0x2e, 0x76, 0x31, 0x42, 0x0e, 0x42, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x50, + 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x40, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, + 0x6f, 0x6d, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x65, 0x76, 0x2f, 0x6d, 0x65, 0x76, 0x2d, 0x63, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x70, 0x32, 0x70, 0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x67, 0x6f, 0x2f, + 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, 0x3b, 0x62, 0x69, 0x64, + 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x42, 0x58, 0x58, 0xaa, 0x02, + 0x0c, 0x42, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0c, + 0x42, 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x18, 0x42, + 0x69, 0x64, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, + 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0d, 0x42, 0x69, 0x64, 0x64, 0x65, 0x72, + 0x61, 0x70, 0x69, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/p2p/gen/go/preconfirmation/v1/preconfirmation.pb.go b/p2p/gen/go/preconfirmation/v1/preconfirmation.pb.go index 658270046..5a84a90e4 100644 --- a/p2p/gen/go/preconfirmation/v1/preconfirmation.pb.go +++ b/p2p/gen/go/preconfirmation/v1/preconfirmation.pb.go @@ -33,6 +33,7 @@ type Bid struct { DecayStartTimestamp int64 `protobuf:"varint,6,opt,name=decay_start_timestamp,json=decayStartTimestamp,proto3" json:"decay_start_timestamp,omitempty"` DecayEndTimestamp int64 `protobuf:"varint,7,opt,name=decay_end_timestamp,json=decayEndTimestamp,proto3" json:"decay_end_timestamp,omitempty"` NikePublicKey []byte `protobuf:"bytes,8,opt,name=nike_public_key,json=nikePublicKey,proto3" json:"nike_public_key,omitempty"` + RevertingTxHashes string `protobuf:"bytes,9,opt,name=reverting_tx_hashes,json=revertingTxHashes,proto3" json:"reverting_tx_hashes,omitempty"` } func (x *Bid) Reset() { @@ -123,6 +124,13 @@ func (x *Bid) GetNikePublicKey() []byte { return nil } +func (x *Bid) GetRevertingTxHashes() string { + if x != nil { + return x.RevertingTxHashes + } + return "" +} + type EncryptedBid struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -334,7 +342,7 @@ var file_preconfirmation_v1_preconfirmation_proto_rawDesc = []byte{ 0x0a, 0x28, 0x70, 0x72, 0x65, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x72, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x76, 0x31, 0x2f, 0x70, 0x72, 0x65, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x72, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x12, 0x70, 0x72, 0x65, 0x63, - 0x6f, 0x6e, 0x66, 0x69, 0x72, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x22, 0xa2, + 0x6f, 0x6e, 0x66, 0x69, 0x72, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x22, 0xd2, 0x02, 0x0a, 0x03, 0x42, 0x69, 0x64, 0x12, 0x17, 0x0a, 0x07, 0x74, 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x78, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x69, 0x64, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, @@ -353,7 +361,10 @@ var file_preconfirmation_v1_preconfirmation_proto_rawDesc = []byte{ 0x6e, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x26, 0x0a, 0x0f, 0x6e, 0x69, 0x6b, 0x65, 0x5f, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0d, 0x6e, 0x69, 0x6b, 0x65, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, - 0x4b, 0x65, 0x79, 0x22, 0x2e, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, + 0x4b, 0x65, 0x79, 0x12, 0x2e, 0x0a, 0x13, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x69, 0x6e, 0x67, + 0x5f, 0x74, 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x11, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x54, 0x78, 0x48, 0x61, 0x73, + 0x68, 0x65, 0x73, 0x22, 0x2e, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x42, 0x69, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x69, 0x70, 0x68, 0x65, 0x72, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x63, 0x69, 0x70, 0x68, 0x65, 0x72, 0x74, 0x65, 0x78, 0x74, 0x22, 0xf1, 0x01, 0x0a, 0x0f, 0x50, 0x72, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, diff --git a/p2p/gen/go/providerapi/v1/providerapi.pb.go b/p2p/gen/go/providerapi/v1/providerapi.pb.go index 80129892c..4f7e08e53 100644 --- a/p2p/gen/go/providerapi/v1/providerapi.pb.go +++ b/p2p/gen/go/providerapi/v1/providerapi.pb.go @@ -231,6 +231,7 @@ type Bid struct { BidDigest []byte `protobuf:"bytes,4,opt,name=bid_digest,json=bidDigest,proto3" json:"bid_digest,omitempty"` DecayStartTimestamp int64 `protobuf:"varint,5,opt,name=decay_start_timestamp,json=decayStartTimestamp,proto3" json:"decay_start_timestamp,omitempty"` DecayEndTimestamp int64 `protobuf:"varint,6,opt,name=decay_end_timestamp,json=decayEndTimestamp,proto3" json:"decay_end_timestamp,omitempty"` + RevertingTxHashes []string `protobuf:"bytes,7,rep,name=reverting_tx_hashes,json=revertingTxHashes,proto3" json:"reverting_tx_hashes,omitempty"` } func (x *Bid) Reset() { @@ -307,6 +308,13 @@ func (x *Bid) GetDecayEndTimestamp() int64 { return 0 } +func (x *Bid) GetRevertingTxHashes() []string { + if x != nil { + return x.RevertingTxHashes + } + return nil +} + type BidResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -446,7 +454,7 @@ var file_providerapi_v1_providerapi_proto_rawDesc = []byte{ 0x37, 0x30, 0x34, 0x38, 0x32, 0x65, 0x34, 0x38, 0x38, 0x64, 0x64, 0x31, 0x62, 0x62, 0x65, 0x35, 0x33, 0x33, 0x61, 0x39, 0x64, 0x34, 0x34, 0x39, 0x37, 0x62, 0x61, 0x38, 0x62, 0x37, 0x35, 0x36, 0x65, 0x31, 0x65, 0x38, 0x32, 0x62, 0x22, 0x7d, 0x22, 0x0e, 0x0a, 0x0c, 0x45, 0x6d, 0x70, 0x74, - 0x79, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0xb1, 0x0c, 0x0a, 0x03, 0x42, 0x69, 0x64, + 0x79, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0xbe, 0x0e, 0x0a, 0x03, 0x42, 0x69, 0x64, 0x12, 0xa3, 0x02, 0x0a, 0x09, 0x74, 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x42, 0x85, 0x02, 0x92, 0x41, 0x78, 0x32, 0x64, 0x48, 0x65, 0x78, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x20, @@ -518,139 +526,156 @@ var file_providerapi_v1_providerapi_proto_rawDesc = []byte{ 0x73, 0x74, 0x20, 0x62, 0x65, 0x20, 0x61, 0x20, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x67, 0x65, 0x72, 0x2e, 0x1a, 0x0e, 0x75, 0x69, 0x6e, 0x74, 0x28, 0x74, 0x68, 0x69, 0x73, 0x29, 0x20, 0x3e, 0x20, 0x30, 0x52, 0x11, 0x64, 0x65, 0x63, 0x61, 0x79, 0x45, 0x6e, 0x64, - 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x3a, 0xb0, 0x03, 0x92, 0x41, 0xac, 0x03, - 0x0a, 0x70, 0x2a, 0x0b, 0x42, 0x69, 0x64, 0x20, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x32, - 0x30, 0x53, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x20, 0x62, 0x69, 0x64, 0x20, 0x6d, 0x65, 0x73, 0x73, - 0x61, 0x67, 0x65, 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x73, - 0x20, 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, - 0x2e, 0xd2, 0x01, 0x08, 0x74, 0x78, 0x48, 0x61, 0x73, 0x68, 0x65, 0x73, 0xd2, 0x01, 0x09, 0x62, - 0x69, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0xd2, 0x01, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, - 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0xd2, 0x01, 0x09, 0x62, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, - 0x73, 0x74, 0x32, 0xb7, 0x02, 0x7b, 0x22, 0x74, 0x78, 0x48, 0x61, 0x73, 0x68, 0x65, 0x73, 0x22, - 0x3a, 0x20, 0x5b, 0x22, 0x66, 0x65, 0x34, 0x63, 0x62, 0x34, 0x37, 0x64, 0x62, 0x33, 0x36, 0x33, - 0x30, 0x35, 0x35, 0x31, 0x62, 0x65, 0x65, 0x64, 0x66, 0x62, 0x64, 0x30, 0x32, 0x61, 0x37, 0x31, - 0x65, 0x63, 0x63, 0x36, 0x39, 0x66, 0x64, 0x35, 0x39, 0x37, 0x35, 0x38, 0x65, 0x32, 0x62, 0x61, - 0x36, 0x39, 0x39, 0x36, 0x30, 0x36, 0x65, 0x32, 0x64, 0x35, 0x63, 0x37, 0x34, 0x32, 0x38, 0x34, - 0x66, 0x66, 0x61, 0x37, 0x22, 0x2c, 0x20, 0x22, 0x37, 0x31, 0x63, 0x31, 0x33, 0x34, 0x38, 0x66, - 0x32, 0x64, 0x37, 0x66, 0x66, 0x37, 0x65, 0x38, 0x31, 0x34, 0x66, 0x39, 0x63, 0x33, 0x36, 0x31, - 0x37, 0x39, 0x38, 0x33, 0x37, 0x30, 0x33, 0x34, 0x33, 0x35, 0x65, 0x61, 0x37, 0x34, 0x34, 0x36, - 0x64, 0x65, 0x34, 0x32, 0x30, 0x61, 0x65, 0x61, 0x63, 0x34, 0x38, 0x38, 0x62, 0x66, 0x31, 0x64, - 0x65, 0x33, 0x35, 0x37, 0x33, 0x37, 0x65, 0x38, 0x22, 0x5d, 0x2c, 0x20, 0x22, 0x61, 0x6d, 0x6f, - 0x75, 0x6e, 0x74, 0x22, 0x3a, 0x20, 0x22, 0x31, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, - 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x22, 0x2c, 0x20, 0x22, 0x62, 0x6c, - 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x22, 0x3a, 0x20, 0x31, 0x32, 0x33, 0x34, - 0x35, 0x36, 0x2c, 0x20, 0x22, 0x62, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x22, 0x3a, - 0x20, 0x22, 0x39, 0x64, 0x4a, 0x69, 0x6e, 0x77, 0x4c, 0x2b, 0x46, 0x5a, 0x36, 0x42, 0x31, 0x78, - 0x73, 0x49, 0x51, 0x51, 0x6f, 0x38, 0x74, 0x38, 0x42, 0x30, 0x5a, 0x58, 0x4a, 0x75, 0x62, 0x4a, - 0x77, 0x59, 0x38, 0x36, 0x6c, 0x2f, 0x59, 0x75, 0x37, 0x79, 0x41, 0x48, 0x31, 0x35, 0x39, 0x51, - 0x72, 0x50, 0x48, 0x55, 0x30, 0x71, 0x6a, 0x32, 0x50, 0x2b, 0x59, 0x46, 0x6a, 0x2b, 0x6c, 0x6c, - 0x62, 0x75, 0x49, 0x31, 0x5a, 0x79, 0x67, 0x64, 0x78, 0x47, 0x73, 0x58, 0x38, 0x2b, 0x50, 0x33, - 0x62, 0x79, 0x4d, 0x45, 0x41, 0x35, 0x69, 0x67, 0x3d, 0x3d, 0x22, 0x7d, 0x22, 0x81, 0x06, 0x0a, - 0x0b, 0x42, 0x69, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x53, 0x0a, 0x0a, - 0x62, 0x69, 0x64, 0x5f, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, - 0x42, 0x34, 0x92, 0x41, 0x31, 0x32, 0x2f, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x20, 0x6f, 0x66, - 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x20, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, - 0x20, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x20, 0x62, 0x79, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, - 0x69, 0x64, 0x64, 0x65, 0x72, 0x2e, 0x52, 0x09, 0x62, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, 0x73, - 0x74, 0x12, 0x5f, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0e, 0x32, 0x22, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, - 0x76, 0x31, 0x2e, 0x42, 0x69, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x53, - 0x74, 0x61, 0x74, 0x75, 0x73, 0x42, 0x23, 0x92, 0x41, 0x14, 0x32, 0x12, 0x53, 0x74, 0x61, 0x74, - 0x75, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x2e, 0xba, 0x48, - 0x09, 0x82, 0x01, 0x06, 0x10, 0x01, 0x1a, 0x02, 0x01, 0x02, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, - 0x75, 0x73, 0x12, 0xb4, 0x01, 0x0a, 0x12, 0x64, 0x69, 0x73, 0x70, 0x61, 0x74, 0x63, 0x68, 0x5f, - 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x42, - 0x84, 0x01, 0x92, 0x41, 0x80, 0x01, 0x32, 0x7e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, - 0x70, 0x20, 0x61, 0x74, 0x20, 0x77, 0x68, 0x69, 0x63, 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x69, 0x73, 0x20, 0x61, 0x63, 0x63, - 0x65, 0x70, 0x74, 0x65, 0x64, 0x20, 0x62, 0x79, 0x20, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, - 0x72, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x69, 0x73, 0x20, 0x75, 0x73, 0x65, 0x64, 0x20, 0x74, 0x6f, - 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x75, 0x74, 0x65, 0x20, 0x74, 0x68, 0x65, 0x20, 0x65, 0x78, 0x70, - 0x65, 0x63, 0x74, 0x65, 0x64, 0x20, 0x72, 0x65, 0x76, 0x65, 0x6e, 0x75, 0x65, 0x20, 0x66, 0x72, - 0x6f, 0x6d, 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x65, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x72, - 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x11, 0x64, 0x69, 0x73, 0x70, 0x61, 0x74, 0x63, 0x68, - 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x22, 0x4a, 0x0a, 0x06, 0x53, 0x74, 0x61, - 0x74, 0x75, 0x73, 0x12, 0x16, 0x0a, 0x12, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x55, 0x4e, - 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x13, 0x0a, 0x0f, 0x53, - 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x41, 0x43, 0x43, 0x45, 0x50, 0x54, 0x45, 0x44, 0x10, 0x01, - 0x12, 0x13, 0x0a, 0x0f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x52, 0x45, 0x4a, 0x45, 0x43, - 0x54, 0x45, 0x44, 0x10, 0x02, 0x3a, 0xb8, 0x02, 0x92, 0x41, 0xb4, 0x02, 0x0a, 0x82, 0x01, 0x2a, - 0x0c, 0x42, 0x69, 0x64, 0x20, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x32, 0x44, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x20, 0x73, 0x65, 0x6e, 0x74, 0x20, 0x62, 0x79, 0x20, - 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x20, 0x77, 0x69, 0x74, - 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x6f, - 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x20, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, - 0x65, 0x64, 0x2e, 0xd2, 0x01, 0x09, 0x62, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0xd2, - 0x01, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0xd2, 0x01, 0x16, 0x64, 0x65, 0x63, 0x61, 0x79, - 0x44, 0x69, 0x73, 0x70, 0x61, 0x74, 0x63, 0x68, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, - 0x70, 0x32, 0xac, 0x01, 0x7b, 0x22, 0x62, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x22, - 0x3a, 0x20, 0x22, 0x39, 0x64, 0x4a, 0x69, 0x6e, 0x77, 0x4c, 0x2b, 0x46, 0x5a, 0x36, 0x42, 0x31, - 0x78, 0x73, 0x49, 0x51, 0x51, 0x6f, 0x38, 0x74, 0x38, 0x42, 0x30, 0x5a, 0x58, 0x4a, 0x75, 0x62, - 0x4a, 0x77, 0x59, 0x38, 0x36, 0x6c, 0x2f, 0x59, 0x75, 0x37, 0x79, 0x41, 0x48, 0x31, 0x35, 0x39, - 0x51, 0x72, 0x50, 0x48, 0x55, 0x30, 0x71, 0x6a, 0x32, 0x50, 0x2b, 0x59, 0x46, 0x6a, 0x2b, 0x6c, - 0x6c, 0x62, 0x75, 0x49, 0x31, 0x5a, 0x79, 0x67, 0x64, 0x78, 0x47, 0x73, 0x58, 0x38, 0x2b, 0x50, - 0x33, 0x62, 0x79, 0x4d, 0x45, 0x41, 0x35, 0x69, 0x67, 0x3d, 0x3d, 0x22, 0x2c, 0x20, 0x22, 0x73, - 0x74, 0x61, 0x74, 0x75, 0x73, 0x22, 0x3a, 0x20, 0x22, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, - 0x41, 0x43, 0x43, 0x45, 0x50, 0x54, 0x45, 0x44, 0x22, 0x2c, 0x20, 0x22, 0x64, 0x65, 0x63, 0x61, - 0x79, 0x44, 0x69, 0x73, 0x70, 0x61, 0x74, 0x63, 0x68, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x22, 0x3a, 0x20, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x30, 0x7d, - 0x32, 0xc5, 0x04, 0x0a, 0x08, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x12, 0x65, 0x0a, - 0x0b, 0x52, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x42, 0x69, 0x64, 0x73, 0x12, 0x1c, 0x2e, 0x70, - 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x6d, - 0x70, 0x74, 0x79, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, 0x13, 0x2e, 0x70, 0x72, 0x6f, - 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x69, 0x64, 0x22, - 0x21, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1b, 0x12, 0x19, 0x2f, 0x76, 0x31, 0x2f, 0x70, 0x72, 0x6f, - 0x76, 0x69, 0x64, 0x65, 0x72, 0x2f, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x5f, 0x62, 0x69, - 0x64, 0x73, 0x30, 0x01, 0x12, 0x7d, 0x0a, 0x11, 0x53, 0x65, 0x6e, 0x64, 0x50, 0x72, 0x6f, 0x63, - 0x65, 0x73, 0x73, 0x65, 0x64, 0x42, 0x69, 0x64, 0x73, 0x12, 0x1b, 0x2e, 0x70, 0x72, 0x6f, 0x76, - 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x69, 0x64, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x1c, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, - 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x4d, 0x65, 0x73, - 0x73, 0x61, 0x67, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x3a, 0x01, 0x2a, 0x22, - 0x20, 0x2f, 0x76, 0x31, 0x2f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2f, 0x73, 0x65, - 0x6e, 0x64, 0x5f, 0x70, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x65, 0x64, 0x5f, 0x62, 0x69, 0x64, - 0x73, 0x28, 0x01, 0x12, 0x7a, 0x0a, 0x0d, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x53, + 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x8a, 0x02, 0x0a, 0x13, 0x72, 0x65, + 0x76, 0x65, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x74, 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, + 0x73, 0x18, 0x07, 0x20, 0x03, 0x28, 0x09, 0x42, 0xd9, 0x01, 0x92, 0x41, 0x49, 0x32, 0x47, 0x4f, + 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x6f, 0x66, + 0x20, 0x74, 0x78, 0x20, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, + 0x61, 0x72, 0x65, 0x20, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x65, 0x64, 0x20, 0x74, 0x6f, 0x20, 0x72, + 0x65, 0x76, 0x65, 0x72, 0x74, 0x20, 0x6f, 0x72, 0x20, 0x62, 0x65, 0x20, 0x64, 0x69, 0x73, 0x63, + 0x61, 0x72, 0x64, 0x65, 0x64, 0x2e, 0xba, 0x48, 0x89, 0x01, 0xba, 0x01, 0x85, 0x01, 0x0a, 0x13, + 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x74, 0x78, 0x5f, 0x68, 0x61, 0x73, + 0x68, 0x65, 0x73, 0x12, 0x41, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x74, + 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x20, 0x6d, 0x75, 0x73, 0x74, 0x20, 0x62, 0x65, + 0x20, 0x61, 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x6f, 0x66, 0x20, 0x76, 0x61, 0x6c, + 0x69, 0x64, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x68, + 0x61, 0x73, 0x68, 0x65, 0x73, 0x2e, 0x1a, 0x2b, 0x74, 0x68, 0x69, 0x73, 0x2e, 0x61, 0x6c, 0x6c, + 0x28, 0x72, 0x2c, 0x20, 0x72, 0x2e, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x65, 0x73, 0x28, 0x27, 0x5e, + 0x5b, 0x61, 0x2d, 0x66, 0x41, 0x2d, 0x46, 0x30, 0x2d, 0x39, 0x5d, 0x7b, 0x36, 0x34, 0x7d, 0x24, + 0x27, 0x29, 0x29, 0x52, 0x11, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x54, 0x78, + 0x48, 0x61, 0x73, 0x68, 0x65, 0x73, 0x3a, 0xb0, 0x03, 0x92, 0x41, 0xac, 0x03, 0x0a, 0x70, 0x2a, + 0x0b, 0x42, 0x69, 0x64, 0x20, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x32, 0x30, 0x53, 0x69, + 0x67, 0x6e, 0x65, 0x64, 0x20, 0x62, 0x69, 0x64, 0x20, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, + 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x62, 0x69, 0x64, 0x64, 0x65, 0x72, 0x73, 0x20, 0x74, 0x6f, + 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2e, 0xd2, 0x01, + 0x08, 0x74, 0x78, 0x48, 0x61, 0x73, 0x68, 0x65, 0x73, 0xd2, 0x01, 0x09, 0x62, 0x69, 0x64, 0x41, + 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0xd2, 0x01, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, + 0x62, 0x65, 0x72, 0xd2, 0x01, 0x09, 0x62, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x32, + 0xb7, 0x02, 0x7b, 0x22, 0x74, 0x78, 0x48, 0x61, 0x73, 0x68, 0x65, 0x73, 0x22, 0x3a, 0x20, 0x5b, + 0x22, 0x66, 0x65, 0x34, 0x63, 0x62, 0x34, 0x37, 0x64, 0x62, 0x33, 0x36, 0x33, 0x30, 0x35, 0x35, + 0x31, 0x62, 0x65, 0x65, 0x64, 0x66, 0x62, 0x64, 0x30, 0x32, 0x61, 0x37, 0x31, 0x65, 0x63, 0x63, + 0x36, 0x39, 0x66, 0x64, 0x35, 0x39, 0x37, 0x35, 0x38, 0x65, 0x32, 0x62, 0x61, 0x36, 0x39, 0x39, + 0x36, 0x30, 0x36, 0x65, 0x32, 0x64, 0x35, 0x63, 0x37, 0x34, 0x32, 0x38, 0x34, 0x66, 0x66, 0x61, + 0x37, 0x22, 0x2c, 0x20, 0x22, 0x37, 0x31, 0x63, 0x31, 0x33, 0x34, 0x38, 0x66, 0x32, 0x64, 0x37, + 0x66, 0x66, 0x37, 0x65, 0x38, 0x31, 0x34, 0x66, 0x39, 0x63, 0x33, 0x36, 0x31, 0x37, 0x39, 0x38, + 0x33, 0x37, 0x30, 0x33, 0x34, 0x33, 0x35, 0x65, 0x61, 0x37, 0x34, 0x34, 0x36, 0x64, 0x65, 0x34, + 0x32, 0x30, 0x61, 0x65, 0x61, 0x63, 0x34, 0x38, 0x38, 0x62, 0x66, 0x31, 0x64, 0x65, 0x33, 0x35, + 0x37, 0x33, 0x37, 0x65, 0x38, 0x22, 0x5d, 0x2c, 0x20, 0x22, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, + 0x22, 0x3a, 0x20, 0x22, 0x31, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, + 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x22, 0x2c, 0x20, 0x22, 0x62, 0x6c, 0x6f, 0x63, 0x6b, + 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x22, 0x3a, 0x20, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x2c, + 0x20, 0x22, 0x62, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x22, 0x3a, 0x20, 0x22, 0x39, + 0x64, 0x4a, 0x69, 0x6e, 0x77, 0x4c, 0x2b, 0x46, 0x5a, 0x36, 0x42, 0x31, 0x78, 0x73, 0x49, 0x51, + 0x51, 0x6f, 0x38, 0x74, 0x38, 0x42, 0x30, 0x5a, 0x58, 0x4a, 0x75, 0x62, 0x4a, 0x77, 0x59, 0x38, + 0x36, 0x6c, 0x2f, 0x59, 0x75, 0x37, 0x79, 0x41, 0x48, 0x31, 0x35, 0x39, 0x51, 0x72, 0x50, 0x48, + 0x55, 0x30, 0x71, 0x6a, 0x32, 0x50, 0x2b, 0x59, 0x46, 0x6a, 0x2b, 0x6c, 0x6c, 0x62, 0x75, 0x49, + 0x31, 0x5a, 0x79, 0x67, 0x64, 0x78, 0x47, 0x73, 0x58, 0x38, 0x2b, 0x50, 0x33, 0x62, 0x79, 0x4d, + 0x45, 0x41, 0x35, 0x69, 0x67, 0x3d, 0x3d, 0x22, 0x7d, 0x22, 0x81, 0x06, 0x0a, 0x0b, 0x42, 0x69, + 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x53, 0x0a, 0x0a, 0x62, 0x69, 0x64, + 0x5f, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x34, 0x92, + 0x41, 0x31, 0x32, 0x2f, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, + 0x65, 0x20, 0x62, 0x69, 0x64, 0x20, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x20, 0x73, 0x69, + 0x67, 0x6e, 0x65, 0x64, 0x20, 0x62, 0x79, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x64, + 0x65, 0x72, 0x2e, 0x52, 0x09, 0x62, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x12, 0x5f, + 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x22, + 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, + 0x42, 0x69, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, + 0x75, 0x73, 0x42, 0x23, 0x92, 0x41, 0x14, 0x32, 0x12, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x20, + 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x2e, 0xba, 0x48, 0x09, 0x82, 0x01, + 0x06, 0x10, 0x01, 0x1a, 0x02, 0x01, 0x02, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, + 0xb4, 0x01, 0x0a, 0x12, 0x64, 0x69, 0x73, 0x70, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x74, 0x69, 0x6d, + 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x42, 0x84, 0x01, 0x92, + 0x41, 0x80, 0x01, 0x32, 0x7e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x20, 0x61, + 0x74, 0x20, 0x77, 0x68, 0x69, 0x63, 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x69, 0x73, 0x20, 0x61, 0x63, 0x63, 0x65, 0x70, 0x74, + 0x65, 0x64, 0x20, 0x62, 0x79, 0x20, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x20, 0x61, + 0x6e, 0x64, 0x20, 0x69, 0x73, 0x20, 0x75, 0x73, 0x65, 0x64, 0x20, 0x74, 0x6f, 0x20, 0x63, 0x6f, + 0x6d, 0x70, 0x75, 0x74, 0x65, 0x20, 0x74, 0x68, 0x65, 0x20, 0x65, 0x78, 0x70, 0x65, 0x63, 0x74, + 0x65, 0x64, 0x20, 0x72, 0x65, 0x76, 0x65, 0x6e, 0x75, 0x65, 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20, + 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x65, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x72, 0x6d, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x11, 0x64, 0x69, 0x73, 0x70, 0x61, 0x74, 0x63, 0x68, 0x54, 0x69, 0x6d, + 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x22, 0x4a, 0x0a, 0x06, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, + 0x12, 0x16, 0x0a, 0x12, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, + 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x13, 0x0a, 0x0f, 0x53, 0x54, 0x41, 0x54, + 0x55, 0x53, 0x5f, 0x41, 0x43, 0x43, 0x45, 0x50, 0x54, 0x45, 0x44, 0x10, 0x01, 0x12, 0x13, 0x0a, + 0x0f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x52, 0x45, 0x4a, 0x45, 0x43, 0x54, 0x45, 0x44, + 0x10, 0x02, 0x3a, 0xb8, 0x02, 0x92, 0x41, 0xb4, 0x02, 0x0a, 0x82, 0x01, 0x2a, 0x0c, 0x42, 0x69, + 0x64, 0x20, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x32, 0x44, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x20, 0x73, 0x65, 0x6e, 0x74, 0x20, 0x62, 0x79, 0x20, 0x74, 0x68, 0x65, + 0x20, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20, 0x74, + 0x68, 0x65, 0x20, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x6e, 0x20, 0x74, + 0x68, 0x65, 0x20, 0x62, 0x69, 0x64, 0x20, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x64, 0x2e, + 0xd2, 0x01, 0x09, 0x62, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0xd2, 0x01, 0x06, 0x73, + 0x74, 0x61, 0x74, 0x75, 0x73, 0xd2, 0x01, 0x16, 0x64, 0x65, 0x63, 0x61, 0x79, 0x44, 0x69, 0x73, + 0x70, 0x61, 0x74, 0x63, 0x68, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x32, 0xac, + 0x01, 0x7b, 0x22, 0x62, 0x69, 0x64, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x22, 0x3a, 0x20, 0x22, + 0x39, 0x64, 0x4a, 0x69, 0x6e, 0x77, 0x4c, 0x2b, 0x46, 0x5a, 0x36, 0x42, 0x31, 0x78, 0x73, 0x49, + 0x51, 0x51, 0x6f, 0x38, 0x74, 0x38, 0x42, 0x30, 0x5a, 0x58, 0x4a, 0x75, 0x62, 0x4a, 0x77, 0x59, + 0x38, 0x36, 0x6c, 0x2f, 0x59, 0x75, 0x37, 0x79, 0x41, 0x48, 0x31, 0x35, 0x39, 0x51, 0x72, 0x50, + 0x48, 0x55, 0x30, 0x71, 0x6a, 0x32, 0x50, 0x2b, 0x59, 0x46, 0x6a, 0x2b, 0x6c, 0x6c, 0x62, 0x75, + 0x49, 0x31, 0x5a, 0x79, 0x67, 0x64, 0x78, 0x47, 0x73, 0x58, 0x38, 0x2b, 0x50, 0x33, 0x62, 0x79, + 0x4d, 0x45, 0x41, 0x35, 0x69, 0x67, 0x3d, 0x3d, 0x22, 0x2c, 0x20, 0x22, 0x73, 0x74, 0x61, 0x74, + 0x75, 0x73, 0x22, 0x3a, 0x20, 0x22, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x41, 0x43, 0x43, + 0x45, 0x50, 0x54, 0x45, 0x44, 0x22, 0x2c, 0x20, 0x22, 0x64, 0x65, 0x63, 0x61, 0x79, 0x44, 0x69, + 0x73, 0x70, 0x61, 0x74, 0x63, 0x68, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x22, + 0x3a, 0x20, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x30, 0x7d, 0x32, 0xc5, 0x04, + 0x0a, 0x08, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x12, 0x65, 0x0a, 0x0b, 0x52, 0x65, + 0x63, 0x65, 0x69, 0x76, 0x65, 0x42, 0x69, 0x64, 0x73, 0x12, 0x1c, 0x2e, 0x70, 0x72, 0x6f, 0x76, + 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, + 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, 0x13, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, + 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x69, 0x64, 0x22, 0x21, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x1b, 0x12, 0x19, 0x2f, 0x76, 0x31, 0x2f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, + 0x65, 0x72, 0x2f, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x5f, 0x62, 0x69, 0x64, 0x73, 0x30, + 0x01, 0x12, 0x7d, 0x0a, 0x11, 0x53, 0x65, 0x6e, 0x64, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, + 0x65, 0x64, 0x42, 0x69, 0x64, 0x73, 0x12, 0x1b, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, + 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x69, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x1a, 0x1c, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, + 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, + 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x3a, 0x01, 0x2a, 0x22, 0x20, 0x2f, 0x76, + 0x31, 0x2f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2f, 0x73, 0x65, 0x6e, 0x64, 0x5f, + 0x70, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x65, 0x64, 0x5f, 0x62, 0x69, 0x64, 0x73, 0x28, 0x01, + 0x12, 0x7a, 0x0a, 0x0d, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x53, 0x74, 0x61, 0x6b, + 0x65, 0x12, 0x1c, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, + 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x6b, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x1d, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, + 0x2e, 0x53, 0x74, 0x61, 0x6b, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2c, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x26, 0x22, 0x24, 0x2f, 0x76, 0x31, 0x2f, 0x70, 0x72, 0x6f, 0x76, + 0x69, 0x64, 0x65, 0x72, 0x2f, 0x72, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x5f, 0x73, 0x74, + 0x61, 0x6b, 0x65, 0x2f, 0x7b, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x7d, 0x12, 0x67, 0x0a, 0x08, + 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x6b, 0x65, 0x12, 0x1c, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, + 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x4d, + 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, 0x1d, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, + 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x6b, 0x65, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x18, 0x12, 0x16, 0x2f, + 0x76, 0x31, 0x2f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2f, 0x67, 0x65, 0x74, 0x5f, + 0x73, 0x74, 0x61, 0x6b, 0x65, 0x12, 0x6e, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x4d, 0x69, 0x6e, 0x53, 0x74, 0x61, 0x6b, 0x65, 0x12, 0x1c, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, - 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x6b, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, + 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x4d, 0x65, 0x73, 0x73, 0x61, + 0x67, 0x65, 0x1a, 0x1d, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x6b, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2c, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x26, 0x22, 0x24, 0x2f, 0x76, 0x31, 0x2f, 0x70, - 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2f, 0x72, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, - 0x5f, 0x73, 0x74, 0x61, 0x6b, 0x65, 0x2f, 0x7b, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x7d, 0x12, - 0x67, 0x0a, 0x08, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x6b, 0x65, 0x12, 0x1c, 0x2e, 0x70, 0x72, - 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x6d, 0x70, - 0x74, 0x79, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, 0x1d, 0x2e, 0x70, 0x72, 0x6f, 0x76, - 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x6b, 0x65, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x18, - 0x12, 0x16, 0x2f, 0x76, 0x31, 0x2f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2f, 0x67, - 0x65, 0x74, 0x5f, 0x73, 0x74, 0x61, 0x6b, 0x65, 0x12, 0x6e, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x4d, - 0x69, 0x6e, 0x53, 0x74, 0x61, 0x6b, 0x65, 0x12, 0x1c, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, - 0x65, 0x72, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x4d, 0x65, - 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, 0x1d, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, - 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x6b, 0x65, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, - 0x31, 0x2f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2f, 0x67, 0x65, 0x74, 0x5f, 0x6d, - 0x69, 0x6e, 0x5f, 0x73, 0x74, 0x61, 0x6b, 0x65, 0x42, 0xbc, 0x02, 0x92, 0x41, 0x74, 0x12, 0x72, - 0x0a, 0x0c, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x20, 0x41, 0x50, 0x49, 0x2a, 0x55, - 0x0a, 0x1b, 0x42, 0x75, 0x73, 0x69, 0x6e, 0x65, 0x73, 0x73, 0x20, 0x53, 0x6f, 0x75, 0x72, 0x63, - 0x65, 0x20, 0x4c, 0x69, 0x63, 0x65, 0x6e, 0x73, 0x65, 0x20, 0x31, 0x2e, 0x31, 0x12, 0x36, 0x68, - 0x74, 0x74, 0x70, 0x73, 0x3a, 0x2f, 0x2f, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, - 0x6d, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x65, 0x76, 0x2f, 0x6d, 0x65, 0x76, 0x2d, 0x63, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x2f, 0x6d, 0x61, 0x69, 0x6e, 0x2f, 0x4c, 0x49, - 0x43, 0x45, 0x4e, 0x53, 0x45, 0x32, 0x0b, 0x31, 0x2e, 0x30, 0x2e, 0x30, 0x2d, 0x61, 0x6c, 0x70, - 0x68, 0x61, 0x0a, 0x12, 0x63, 0x6f, 0x6d, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, - 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x42, 0x10, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, - 0x61, 0x70, 0x69, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, - 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x65, 0x76, 0x2f, 0x6d, 0x65, - 0x76, 0x2d, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x70, 0x32, 0x70, 0x2f, 0x67, 0x65, 0x6e, - 0x2f, 0x67, 0x6f, 0x2f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2f, - 0x76, 0x31, 0x3b, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x76, 0x31, - 0xa2, 0x02, 0x03, 0x50, 0x58, 0x58, 0xaa, 0x02, 0x0e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, - 0x72, 0x61, 0x70, 0x69, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, - 0x65, 0x72, 0x61, 0x70, 0x69, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1a, 0x50, 0x72, 0x6f, 0x76, 0x69, - 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, - 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0f, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, - 0x61, 0x70, 0x69, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x31, 0x2f, 0x70, + 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2f, 0x67, 0x65, 0x74, 0x5f, 0x6d, 0x69, 0x6e, 0x5f, + 0x73, 0x74, 0x61, 0x6b, 0x65, 0x42, 0xbc, 0x02, 0x92, 0x41, 0x74, 0x12, 0x72, 0x0a, 0x0c, 0x50, + 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x20, 0x41, 0x50, 0x49, 0x2a, 0x55, 0x0a, 0x1b, 0x42, + 0x75, 0x73, 0x69, 0x6e, 0x65, 0x73, 0x73, 0x20, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x4c, + 0x69, 0x63, 0x65, 0x6e, 0x73, 0x65, 0x20, 0x31, 0x2e, 0x31, 0x12, 0x36, 0x68, 0x74, 0x74, 0x70, + 0x73, 0x3a, 0x2f, 0x2f, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x70, + 0x72, 0x69, 0x6d, 0x65, 0x76, 0x2f, 0x6d, 0x65, 0x76, 0x2d, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x2f, 0x6d, 0x61, 0x69, 0x6e, 0x2f, 0x4c, 0x49, 0x43, 0x45, 0x4e, + 0x53, 0x45, 0x32, 0x0b, 0x31, 0x2e, 0x30, 0x2e, 0x30, 0x2d, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x0a, + 0x12, 0x63, 0x6f, 0x6d, 0x2e, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, + 0x2e, 0x76, 0x31, 0x42, 0x10, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, + 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, + 0x63, 0x6f, 0x6d, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x65, 0x76, 0x2f, 0x6d, 0x65, 0x76, 0x2d, 0x63, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x70, 0x32, 0x70, 0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x67, 0x6f, + 0x2f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, 0x3b, + 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, 0x76, 0x31, 0xa2, 0x02, 0x03, + 0x50, 0x58, 0x58, 0xaa, 0x02, 0x0e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, + 0x69, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, + 0x70, 0x69, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1a, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, + 0x61, 0x70, 0x69, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0xea, 0x02, 0x0f, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x61, 0x70, 0x69, + 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/p2p/gen/openapi/bidderapi/v1/bidderapi.swagger.yaml b/p2p/gen/openapi/bidderapi/v1/bidderapi.swagger.yaml index 0fbdabdbd..36a940371 100644 --- a/p2p/gen/openapi/bidderapi/v1/bidderapi.swagger.yaml +++ b/p2p/gen/openapi/bidderapi/v1/bidderapi.swagger.yaml @@ -157,6 +157,11 @@ definitions: type: string format: int64 description: Timestamp at which the bid ends decaying. + revertingTxHashes: + type: array + items: + type: string + description: Optional array of tx hashes that are allowed to revert or be discarded. description: Unsigned bid message from bidders to the bidder mev-commit node. title: Bid message required: @@ -225,6 +230,11 @@ definitions: type: string format: int64 description: Timestamp at which the commitment is published. + revertingTxHashes: + type: array + items: + type: string + description: Optional array of tx hashes that are allowed to revert or be discarded. v1DepositResponse: type: object example: diff --git a/p2p/gen/openapi/providerapi/v1/providerapi.swagger.yaml b/p2p/gen/openapi/providerapi/v1/providerapi.swagger.yaml index adfdab05b..35f648303 100644 --- a/p2p/gen/openapi/providerapi/v1/providerapi.swagger.yaml +++ b/p2p/gen/openapi/providerapi/v1/providerapi.swagger.yaml @@ -165,6 +165,11 @@ definitions: type: string format: int64 description: Timestamp at which the bid ends decaying. + revertingTxHashes: + type: array + items: + type: string + description: Optional array of tx hashes that are allowed to revert or be discarded. description: Signed bid message from bidders to the provider. title: Bid message required: diff --git a/p2p/messages/preconfirmation/v1/preconfirmation.proto b/p2p/messages/preconfirmation/v1/preconfirmation.proto index 43b6a515f..34ebd71f9 100644 --- a/p2p/messages/preconfirmation/v1/preconfirmation.proto +++ b/p2p/messages/preconfirmation/v1/preconfirmation.proto @@ -11,6 +11,7 @@ message Bid { int64 decay_start_timestamp = 6; int64 decay_end_timestamp = 7; bytes nike_public_key = 8; + string reverting_tx_hashes = 9; }; message EncryptedBid { diff --git a/p2p/pkg/preconfirmation/preconfirmation.go b/p2p/pkg/preconfirmation/preconfirmation.go index 6d862ccce..7542b3501 100644 --- a/p2p/pkg/preconfirmation/preconfirmation.go +++ b/p2p/pkg/preconfirmation/preconfirmation.go @@ -119,6 +119,7 @@ func (p *Preconfirmation) SendBid( blockNumber int64, decayStartTimestamp int64, decayEndTimestamp int64, + revertingTxHashes string, ) (chan *preconfpb.PreConfirmation, error) { startTime := time.Now() bid, encryptedBid, nikePrivateKey, err := p.encryptor.ConstructEncryptedBid( @@ -127,6 +128,7 @@ func (p *Preconfirmation) SendBid( blockNumber, decayStartTimestamp, decayEndTimestamp, + revertingTxHashes, ) if err != nil { p.logger.Error("constructing encrypted bid", "error", err, "txHash", txHash) diff --git a/p2p/pkg/preconfirmation/preconfirmation_test.go b/p2p/pkg/preconfirmation/preconfirmation_test.go index d587e4acd..121afbef6 100644 --- a/p2p/pkg/preconfirmation/preconfirmation_test.go +++ b/p2p/pkg/preconfirmation/preconfirmation_test.go @@ -45,7 +45,7 @@ type testEncryptor struct { preConfirmationSigner common.Address } -func (t *testEncryptor) ConstructEncryptedBid(_ string, _ string, _ int64, _ int64, _ int64) (*preconfpb.Bid, *preconfpb.EncryptedBid, *ecdh.PrivateKey, error) { +func (t *testEncryptor) ConstructEncryptedBid(_ string, _ string, _ int64, _ int64, _ int64, _ string) (*preconfpb.Bid, *preconfpb.EncryptedBid, *ecdh.PrivateKey, error) { return t.bid, t.encryptedBid, t.nikePrivateKey, nil } @@ -211,7 +211,7 @@ func TestPreconfBidSubmission(t *testing.T) { svc.SetPeerHandler(server, p.Streams()[0]) - respC, err := p.SendBid(context.Background(), bid.TxHash, bid.BidAmount, bid.BlockNumber, bid.DecayStartTimestamp, bid.DecayEndTimestamp) + respC, err := p.SendBid(context.Background(), bid.TxHash, bid.BidAmount, bid.BlockNumber, bid.DecayStartTimestamp, bid.DecayEndTimestamp, "") if err != nil { t.Fatal(err) } diff --git a/p2p/pkg/preconfirmation/tracker/tracker.go b/p2p/pkg/preconfirmation/tracker/tracker.go index 10d2d770f..00fc6ca5f 100644 --- a/p2p/pkg/preconfirmation/tracker/tracker.go +++ b/p2p/pkg/preconfirmation/tracker/tracker.go @@ -32,9 +32,9 @@ type Tracker struct { newL1Blocks chan *blocktracker.BlocktrackerNewL1Block enryptedCmts chan *preconfcommstore.PreconfcommitmentstoreEncryptedCommitmentStored commitments chan *preconfcommstore.PreconfcommitmentstoreCommitmentStored - winners map[int64]*blocktracker.BlocktrackerNewL1Block - metrics *metrics - logger *slog.Logger + winners map[int64]*blocktracker.BlocktrackerNewL1Block + metrics *metrics + logger *slog.Logger } type OptsGetter func(context.Context) (*bind.TransactOpts, error) @@ -60,6 +60,7 @@ type PreconfContract interface { bid *big.Int, blockNumber uint64, txnHash string, + revertingTxHashes string, decayStartTimeStamp uint64, decayEndTimeStamp uint64, bidSignature []byte, @@ -89,9 +90,9 @@ func NewTracker( newL1Blocks: make(chan *blocktracker.BlocktrackerNewL1Block), enryptedCmts: make(chan *preconfcommstore.PreconfcommitmentstoreEncryptedCommitmentStored), commitments: make(chan *preconfcommstore.PreconfcommitmentstoreCommitmentStored), - winners: make(map[int64]*blocktracker.BlocktrackerNewL1Block), - metrics: newMetrics(), - logger: logger, + winners: make(map[int64]*blocktracker.BlocktrackerNewL1Block), + metrics: newMetrics(), + logger: logger, } } @@ -268,12 +269,14 @@ func (t *Tracker) handleNewL1Block( // for bidder to open is only in cases of slashes as he will get refund. Only one // of bidder or provider should open the commitment as 1 of the txns would // fail. This delay is to ensure this. + t.logger.Info("bidder detected, processing block 1 behind the current one") t.winners[newL1Block.BlockNumber.Int64()] = newL1Block pastBlock, ok := t.winners[newL1Block.BlockNumber.Int64()-2] if !ok { return nil } newL1Block = pastBlock + t.logger.Info("processing past block", "blockNumber", pastBlock.BlockNumber) for k := range t.winners { if k < pastBlock.BlockNumber.Int64() { delete(t.winners, k) @@ -283,6 +286,7 @@ func (t *Tracker) handleNewL1Block( commitments, err := t.store.GetCommitmentsByBlockNumber(newL1Block.BlockNumber.Int64()) if err != nil { + t.logger.Error("failed to get commitments by block number", "blockNumber", newL1Block.BlockNumber, "error", err) return err } @@ -324,6 +328,7 @@ func (t *Tracker) handleNewL1Block( bidAmt, uint64(commitment.PreConfirmation.Bid.BlockNumber), commitment.PreConfirmation.Bid.TxHash, + commitment.PreConfirmation.Bid.RevertingTxHashes, uint64(commitment.PreConfirmation.Bid.DecayStartTimestamp), uint64(commitment.PreConfirmation.Bid.DecayEndTimestamp), commitment.PreConfirmation.Bid.Signature, @@ -345,15 +350,11 @@ func (t *Tracker) handleNewL1Block( err = t.store.DeleteCommitmentByBlockNumber(newL1Block.BlockNumber.Int64()) if err != nil { - t.logger.Error("failed to delete commitments by block number", "error", err) + t.logger.Error("failed to delete commitments by block number", "blockNumber", newL1Block.BlockNumber, "error", err) return err } openDuration := time.Since(openStart) - t.metrics.totalCommitmentsToOpen.Add(float64(len(commitments))) - t.metrics.totalOpenedCommitments.Add(float64(settled)) - t.metrics.blockCommitmentProcessDuration.Set(float64(openDuration)) - t.logger.Info("commitments opened", "blockNumber", newL1Block.BlockNumber, "total", len(commitments), @@ -362,7 +363,12 @@ func (t *Tracker) handleNewL1Block( "duration", openDuration, ) + t.metrics.totalCommitmentsToOpen.Add(float64(len(commitments))) + t.metrics.totalOpenedCommitments.Add(float64(settled)) + t.metrics.blockCommitmentProcessDuration.Set(float64(openDuration)) + if len(failedCommitments) > 0 { + t.logger.Info("processing failed commitments", "count", len(failedCommitments)) receipts, err := t.receiptGetter.BatchReceipts(ctx, failedCommitments) if err != nil { t.logger.Warn("failed to get receipts for failed commitments", "error", err) diff --git a/p2p/pkg/preconfirmation/tracker/tracker_test.go b/p2p/pkg/preconfirmation/tracker/tracker_test.go index b370ef868..ee8aa229d 100644 --- a/p2p/pkg/preconfirmation/tracker/tracker_test.go +++ b/p2p/pkg/preconfirmation/tracker/tracker_test.go @@ -158,6 +158,7 @@ func TestTracker(t *testing.T) { DecayStartTimeStamp: uint64(commitments[4].PreConfirmation.Bid.DecayStartTimestamp), DecayEndTimeStamp: uint64(commitments[4].PreConfirmation.Bid.DecayEndTimestamp), TxnHash: commitments[4].PreConfirmation.Bid.TxHash, + RevertingTxHashes: commitments[4].PreConfirmation.Bid.RevertingTxHashes, CommitmentHash: common.BytesToHash(commitments[4].PreConfirmation.Digest), BidSignature: commitments[4].PreConfirmation.Bid.Signature, CommitmentSignature: commitments[4].PreConfirmation.Signature, @@ -280,6 +281,9 @@ func TestTracker(t *testing.T) { oc.decayStartTimeStamp, ) } + if c.PreConfirmation.Bid.RevertingTxHashes != oc.revertingTxHashes { + t.Fatalf("expected reverting tx hashes %s, got %s", c.PreConfirmation.Bid.RevertingTxHashes, oc.revertingTxHashes) + } if c.PreConfirmation.Bid.DecayEndTimestamp != int64(oc.decayEndTimeStamp) { t.Fatalf("expected decay end timestamp %d, got %d", c.PreConfirmation.Bid.DecayEndTimestamp, oc.decayEndTimeStamp) } @@ -316,6 +320,7 @@ type openedCommitment struct { bid *big.Int blockNumber uint64 txnHash string + revertingTxHashes string decayStartTimeStamp uint64 decayEndTimeStamp uint64 bidSignature []byte @@ -333,6 +338,7 @@ func (t *testPreconfContract) OpenCommitment( bid *big.Int, blockNumber uint64, txnHash string, + revertingTxHashes string, decayStartTimeStamp uint64, decayEndTimeStamp uint64, bidSignature []byte, @@ -344,6 +350,7 @@ func (t *testPreconfContract) OpenCommitment( bid: bid, blockNumber: blockNumber, txnHash: txnHash, + revertingTxHashes: revertingTxHashes, decayStartTimeStamp: decayStartTimeStamp, decayEndTimeStamp: decayEndTimeStamp, bidSignature: bidSignature, @@ -417,6 +424,7 @@ func publishCommitment( c.DecayStartTimeStamp, c.DecayEndTimeStamp, c.TxnHash, + c.RevertingTxHashes, c.CommitmentHash, c.BidSignature, c.CommitmentSignature, diff --git a/p2p/pkg/rpc/bidder/service.go b/p2p/pkg/rpc/bidder/service.go index 6c5d99185..79dc4f6c0 100644 --- a/p2p/pkg/rpc/bidder/service.go +++ b/p2p/pkg/rpc/bidder/service.go @@ -60,7 +60,7 @@ func NewService( } type PreconfSender interface { - SendBid(context.Context, string, string, int64, int64, int64) (chan *preconfirmationv1.PreConfirmation, error) + SendBid(ctx context.Context, txnsStr string, amount string, blockNumber int64, decayStartTimestamp int64, decayEndTimestamp int64, revertingTxHashes string) (chan *preconfirmationv1.PreConfirmation, error) } type BidderRegistryContract interface { @@ -99,6 +99,7 @@ func (s *Service) SendBid( } txnsStr := strings.Join(bid.TxHashes, ",") + revertingTxHashesStr := strings.Join(bid.RevertingTxHashes, ",") respC, err := s.sender.SendBid( ctx, @@ -107,6 +108,7 @@ func (s *Service) SendBid( bid.BlockNumber, bid.DecayStartTimestamp, bid.DecayEndTimestamp, + revertingTxHashesStr, ) if err != nil { s.logger.Error("sending bid", "error", err) diff --git a/p2p/pkg/rpc/bidder/service_test.go b/p2p/pkg/rpc/bidder/service_test.go index 710c2e4cc..e991aa8ff 100644 --- a/p2p/pkg/rpc/bidder/service_test.go +++ b/p2p/pkg/rpc/bidder/service_test.go @@ -48,6 +48,7 @@ func (s *testSender) SendBid( blockNum int64, decayStartTimestamp int64, decayEndTimestamp int64, + revertedTxns string, ) (chan *preconfpb.PreConfirmation, error) { s.bids = append(s.bids, bid{ txHex: txHex, @@ -66,6 +67,7 @@ func (s *testSender) SendBid( DecayEndTimestamp: decayEndTimestamp, Digest: []byte("digest"), Signature: []byte("signature"), + RevertingTxHashes: revertedTxns, }, Digest: []byte("digest"), Signature: []byte("signature"), @@ -362,6 +364,7 @@ func TestSendBid(t *testing.T) { BlockNumber: tc.blockNum, DecayStartTimestamp: tc.decayStartTimestamp, DecayEndTimestamp: tc.decayEndTimestamp, + RevertingTxHashes: []string{}, }) if err != nil { t.Fatalf("error sending bid: %v", err) diff --git a/p2p/pkg/signer/preconfencryptor/encryptor.go b/p2p/pkg/signer/preconfencryptor/encryptor.go index 86f898ceb..9614345e4 100644 --- a/p2p/pkg/signer/preconfencryptor/encryptor.go +++ b/p2p/pkg/signer/preconfencryptor/encryptor.go @@ -32,7 +32,7 @@ var ( ) type Encryptor interface { - ConstructEncryptedBid(string, string, int64, int64, int64) (*preconfpb.Bid, *preconfpb.EncryptedBid, *ecdh.PrivateKey, error) + ConstructEncryptedBid(string, string, int64, int64, int64, string) (*preconfpb.Bid, *preconfpb.EncryptedBid, *ecdh.PrivateKey, error) ConstructEncryptedPreConfirmation(*preconfpb.Bid) (*preconfpb.PreConfirmation, *preconfpb.EncryptedPreConfirmation, error) VerifyBid(*preconfpb.Bid) (*common.Address, error) VerifyEncryptedPreConfirmation(providerNikePK *ecdh.PublicKey, bidderNikeSC *ecdh.PrivateKey, bidHash []byte, c *preconfpb.EncryptedPreConfirmation) ([]byte, *common.Address, error) @@ -85,6 +85,7 @@ func (e *encryptor) ConstructEncryptedBid( blockNumber int64, decayStartTimeStamp int64, decayEndTimeStamp int64, + revertingTxHashes string, ) (*preconfpb.Bid, *preconfpb.EncryptedBid, *ecdh.PrivateKey, error) { if txHash == "" || bidAmt == "" || blockNumber == 0 { return nil, nil, nil, ErrMissingRequiredFields @@ -96,6 +97,7 @@ func (e *encryptor) ConstructEncryptedBid( BlockNumber: blockNumber, DecayStartTimestamp: decayStartTimeStamp, DecayEndTimestamp: decayEndTimeStamp, + RevertingTxHashes: revertingTxHashes, } bidHash, err := GetBidHash(bid) @@ -305,18 +307,20 @@ func GetBidHash(bid *preconfpb.Bid) ([]byte, error) { return nil, ErrInvalidBidAmt } - // EIP712_MESSAGE_TYPEHASH + // EIP712_BID_TYPEHASH eip712MessageTypeHash := crypto.Keccak256Hash( - []byte("PreConfBid(string txnHash,uint256 bid,uint64 blockNumber,uint64 decayStartTimeStamp,uint64 decayEndTimeStamp)"), + []byte("PreConfBid(string txnHash,string revertingTxHashes,uint256 bid,uint64 blockNumber,uint64 decayStartTimeStamp,uint64 decayEndTimeStamp)"), ) // Convert the txnHash to a byte array and hash it txnHashHash := crypto.Keccak256Hash([]byte(bid.TxHash)) + revertingTxHashesHash := crypto.Keccak256Hash([]byte(bid.RevertingTxHashes)) // Encode values similar to Solidity's abi.encode // The reason we use math.U256Bytes is because we want to encode the uint64 as a 32 byte array // The EVM does this for values due via padding to 32 bytes, as that's the base size of a word in the EVM data := append(eip712MessageTypeHash.Bytes(), txnHashHash.Bytes()...) + data = append(data, revertingTxHashesHash.Bytes()...) data = append(data, math.U256Bytes(bidAmt)...) data = append(data, math.U256Bytes(big.NewInt(bid.BlockNumber))...) data = append(data, math.U256Bytes(big.NewInt(bid.DecayStartTimestamp))...) @@ -348,19 +352,21 @@ func GetPreConfirmationHash(c *preconfpb.PreConfirmation) ([]byte, error) { return nil, ErrInvalidBidAmt } - // EIP712_MESSAGE_TYPEHASH + // EIP712_COMMITMENT_TYPEHASH eip712MessageTypeHash := crypto.Keccak256Hash( - []byte("PreConfCommitment(string txnHash,uint256 bid,uint64 blockNumber,uint64 decayStartTimeStamp,uint64 decayEndTimeStamp,bytes32 bidHash,string signature,string sharedSecretKey)"), + []byte("PreConfCommitment(string txnHash,string revertingTxHashes,uint256 bid,uint64 blockNumber,uint64 decayStartTimeStamp,uint64 decayEndTimeStamp,bytes32 bidHash,string signature,string sharedSecretKey)"), ) // Convert the txnHash to a byte array and hash it txnHashHash := crypto.Keccak256Hash([]byte(c.Bid.TxHash)) + revertingTxHashesHash := crypto.Keccak256Hash([]byte(c.Bid.RevertingTxHashes)) bidDigestHash := crypto.Keccak256Hash([]byte(hex.EncodeToString(c.Bid.Digest))) bidSigHash := crypto.Keccak256Hash([]byte(hex.EncodeToString(c.Bid.Signature))) sharedSecretHash := crypto.Keccak256Hash([]byte(hex.EncodeToString(c.SharedSecret))) // Encode values similar to Solidity's abi.encode data := append(eip712MessageTypeHash.Bytes(), txnHashHash.Bytes()...) + data = append(data, revertingTxHashesHash.Bytes()...) data = append(data, math.U256Bytes(bidAmt)...) data = append(data, math.U256Bytes(big.NewInt(c.Bid.BlockNumber))...) data = append(data, math.U256Bytes(big.NewInt(c.Bid.DecayStartTimestamp))...) diff --git a/p2p/pkg/signer/preconfencryptor/encryptor_test.go b/p2p/pkg/signer/preconfencryptor/encryptor_test.go index 3dc714b8c..60a369298 100644 --- a/p2p/pkg/signer/preconfencryptor/encryptor_test.go +++ b/p2p/pkg/signer/preconfencryptor/encryptor_test.go @@ -44,7 +44,7 @@ func TestBids(t *testing.T) { } start := time.Now().UnixMilli() end := start + 100000 - _, encryptedBid, _, err := encryptor.ConstructEncryptedBid("0xkartik", "10", 2, start, end) + _, encryptedBid, _, err := encryptor.ConstructEncryptedBid("0xkartik", "10", 2, start, end, "") if err != nil { t.Fatal(err) } @@ -123,7 +123,7 @@ func TestBids(t *testing.T) { start := time.Now().UnixMilli() end := start + 100000 - bid, encryptedBid, nikePrivateKey, err := bidderEncryptor.ConstructEncryptedBid("0xkartik", "10", 2, start, end) + bid, encryptedBid, nikePrivateKey, err := bidderEncryptor.ConstructEncryptedBid("0xkartik", "10", 2, start, end, "") if err != nil { t.Fatal(err) } @@ -152,6 +152,7 @@ func TestHashing(t *testing.T) { t.Run("bid", func(t *testing.T) { bid := &preconfpb.Bid{ TxHash: "0xkartik", + RevertingTxHashes: "0xkartik", BidAmount: "2", BlockNumber: 2, DecayStartTimestamp: 10, @@ -165,15 +166,36 @@ func TestHashing(t *testing.T) { hashStr := hex.EncodeToString(hash) // This hash is sourced from the solidity contract to ensure interoperability - expHash := "56c06a13be335eba981b780ea45dff258a7c429d0e9d993235ef2d3a7e435df8" + expHash := "9890bcda118cfabed02ff3b9d05a54dca5310e9ace3b05f259f4731f58ad0900" if hashStr != expHash { t.Fatalf("hash mismatch: %s != %s", hashStr, expHash) } + + alicePrivateKey, err := crypto.HexToECDSA("9C0257114EB9399A2985F8E75DAD7600C5D89FE3824FFA99EC1C3EB8BF3B0501") + if err != nil { + t.Fatal(err) + } + + expHashBytes, err := hex.DecodeString(expHash) + if err != nil { + t.Fatal(err) + } + + signature, err := crypto.Sign(expHashBytes, alicePrivateKey) + if err != nil { + t.Fatal(err) + } + + t.Logf("Signature: %s", hex.EncodeToString(signature)) + + // Log the keccak of the signature + signatureHash := crypto.Keccak256Hash(signature) + t.Logf("Keccak256 of Signature: %s", signatureHash.Hex()) }) t.Run("preConfirmation", func(t *testing.T) { - bidHash := "56c06a13be335eba981b780ea45dff258a7c429d0e9d993235ef2d3a7e435df8" - bidSignature := "2e7df27808c72d7d5b2543bb63b06c0ae2144e021593b8d2a7cca6a3fb2d9c4b1a82dd2a07266de9364d255bdb709476ad96b826ec855efb528eaff66682997e1c" + bidHash := "9890bcda118cfabed02ff3b9d05a54dca5310e9ace3b05f259f4731f58ad0900" + bidSignature := "f9b66c6d57dac947a3aa2b37010df745592cf57f907d437767bc0af6d44b3dc1112168e4cab311d6dfddf7f58c0d07bb95403fca2cc48d4450e088cf9ee894c81b" bidHashBytes, err := hex.DecodeString(bidHash) if err != nil { @@ -186,6 +208,7 @@ func TestHashing(t *testing.T) { bid := &preconfpb.Bid{ TxHash: "0xkartik", + RevertingTxHashes: "0xkartik", BidAmount: "2", BlockNumber: 2, DecayStartTimestamp: 10, @@ -205,20 +228,32 @@ func TestHashing(t *testing.T) { if err != nil { t.Fatal(err) } - hashStr := hex.EncodeToString(hash) - expHash := "9d954942ad3f6cb41ccd029869be7b28036270b4754665a3783c2d6bf0ef7d08" + expHash := "8257770d4be5c4b622e6bd6b45ff8deb6602235f3aa844b774eb21800eb4923a" if hashStr != expHash { t.Fatalf("hash mismatch: %s != %s", hashStr, expHash) } + + // Sign the hash with Bob's private key + bobPrivateKey, err := crypto.HexToECDSA("38E47A7B719DCE63662AEAF43440326F551B8A7EE198CEE35CB5D517F2D296A2") + if err != nil { + t.Fatal(err) + } + + signature, err := crypto.Sign(hash, bobPrivateKey) + if err != nil { + t.Fatal(err) + } + + t.Logf("Bob's Signature: %s", hex.EncodeToString(signature)) }) } func TestVerify(t *testing.T) { t.Parallel() - bidSig := "8af22e36247e14ba05d3a5a3cc62eee708cfd9ce293c0aebcbe7f89229f6db56638af8427806247d9abb295f681c1a2f2bb127f3bf80799f80d62b252cce04d91c" - bidHash := "2574b1ab8a90e173528ddee748be8e8e696b1f0cf687f75966550f5e9ef408b0" + bidSig := "f9b66c6d57dac947a3aa2b37010df745592cf57f907d437767bc0af6d44b3dc1112168e4cab311d6dfddf7f58c0d07bb95403fca2cc48d4450e088cf9ee894c800" + bidHash := "9890bcda118cfabed02ff3b9d05a54dca5310e9ace3b05f259f4731f58ad0900" bidHashBytes, err := hex.DecodeString(bidHash) if err != nil { @@ -240,7 +275,7 @@ func TestVerify(t *testing.T) { t.Fatal(err) } - expOwner := "0x8339F9E3d7B2693aD8955Aa5EC59D56669A84d60" + expOwner := "0x328809Bc894f92807417D2dAD6b7C998c1aFdac6" if owner.Hex() != expOwner { t.Fatalf("owner mismatch: %s != %s", owner.Hex(), expOwner) } @@ -309,7 +344,7 @@ func BenchmarkConstructEncryptedBid(b *testing.B) { b.ResetTimer() // Benchmark loop for i := 0; i < b.N; i++ { - _, _, _, err := encryptor.ConstructEncryptedBid(bids[i].hash, bids[i].amount, bids[i].blocknumber, bids[i].start, bids[i].end) + _, _, _, err := encryptor.ConstructEncryptedBid(bids[i].hash, bids[i].amount, bids[i].blocknumber, bids[i].start, bids[i].end, "") if err != nil { b.Fatal(err) } @@ -368,7 +403,7 @@ func BenchmarkConstructEncryptedPreConfirmation(b *testing.B) { if err != nil { b.Fatal(err) } - bids[i], _, _, err = bidderEncryptor.ConstructEncryptedBid(bid.hash, bid.amount, bid.blocknumber, bid.start, bid.end) + bids[i], _, _, err = bidderEncryptor.ConstructEncryptedBid(bid.hash, bid.amount, bid.blocknumber, bid.start, bid.end, "") if err != nil { b.Fatal(err) } diff --git a/p2p/rpc/bidderapi/v1/bidderapi.proto b/p2p/rpc/bidderapi/v1/bidderapi.proto index 77391c04c..c319dc640 100644 --- a/p2p/rpc/bidderapi/v1/bidderapi.proto +++ b/p2p/rpc/bidderapi/v1/bidderapi.proto @@ -192,6 +192,13 @@ message Bid { message: "decay_end_timestamp must be a valid integer.", expression: "uint(this) > 0" }]; + repeated string reverting_tx_hashes = 6 [(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = { + description: "Optional array of tx hashes that are allowed to revert or be discarded." + }, (buf.validate.field).cel = { + id: "reverting_tx_hashes", + message: "reverting_tx_hashes must be an array of valid transaction hashes.", + expression: "this.all(r, r.matches('^[a-fA-F0-9]{64}$'))" + }]; }; message Commitment { @@ -229,4 +236,7 @@ message Commitment { int64 dispatch_timestamp = 11 [(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = { description: "Timestamp at which the commitment is published." }]; + repeated string reverting_tx_hashes = 12 [(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = { + description: "Optional array of tx hashes that are allowed to revert or be discarded." + }]; }; diff --git a/p2p/rpc/providerapi/v1/providerapi.proto b/p2p/rpc/providerapi/v1/providerapi.proto index 4030af74a..089b979f3 100644 --- a/p2p/rpc/providerapi/v1/providerapi.proto +++ b/p2p/rpc/providerapi/v1/providerapi.proto @@ -144,6 +144,13 @@ message Bid { message: "decay_end_timestamp must be a valid integer.", expression: "uint(this) > 0" }]; + repeated string reverting_tx_hashes = 7 [(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = { + description: "Optional array of tx hashes that are allowed to revert or be discarded." + }, (buf.validate.field).cel = { + id: "reverting_tx_hashes", + message: "reverting_tx_hashes must be an array of valid transaction hashes.", + expression: "this.all(r, r.matches('^[a-fA-F0-9]{64}$'))" + }]; }; message BidResponse { diff --git a/x/contracts/txmonitor/eth_helper.go b/x/contracts/txmonitor/eth_helper.go index 4826c08b8..a44ed9a12 100644 --- a/x/contracts/txmonitor/eth_helper.go +++ b/x/contracts/txmonitor/eth_helper.go @@ -118,7 +118,7 @@ func (e *evmHelper) BatchReceipts(ctx context.Context, txHashes []common.Hash) ( var receipts []Result var err error for attempts := 0; attempts < 50; attempts++ { - e.logger.Debug("Attempting batch call", "attempt", attempts+1) + e.logger.Info("Attempting batch call", "attempt", attempts+1) // Execute the batch request err = e.client.BatchCallContext(context.Background(), batch) if err != nil { @@ -134,6 +134,7 @@ func (e *evmHelper) BatchReceipts(ctx context.Context, txHashes []common.Hash) ( e.logger.Error("All batch call attempts failed", "error", err) return nil, err } + receipts = make([]Result, len(batch)) for i, elem := range batch { e.logger.Debug("Processing batch element", "index", i, "result", elem.Result, "error", elem.Error) @@ -143,6 +144,24 @@ func (e *evmHelper) BatchReceipts(ctx context.Context, txHashes []common.Hash) ( } } + // Retry individual failed transactions + for i, receipt := range receipts { + if receipt.Err != nil { + e.logger.Info("Retrying failed transaction", "index", i, "hash", txHashes[i].Hex()) + for attempts := 0; attempts < 50; attempts++ { + e.logger.Info("Attempting individual call", "attempt", attempts+1, "hash", txHashes[i].Hex()) + err = e.client.CallContext(context.Background(), receipt.Receipt, "eth_getTransactionReceipt", txHashes[i]) + if err == nil { + e.logger.Info("Individual call succeeded", "attempt", attempts+1, "hash", txHashes[i].Hex()) + receipts[i].Err = nil + break + } + e.logger.Error("Individual call attempt failed", "attempt", attempts+1, "hash", txHashes[i].Hex(), "error", err) + time.Sleep(1 * time.Second) + } + } + } + e.logger.Info("BatchReceipts completed successfully", "receipts", receipts) return receipts, nil }