diff --git a/.gitleaksignore b/.gitleaksignore index 8b8c75af..9e1017dd 100644 --- a/.gitleaksignore +++ b/.gitleaksignore @@ -452,4 +452,10 @@ cd3b8c411856aa346cdcc75db3b819447990d327:scripts/deployment/globals_mainnet.json 894bdea54c5b2ec7a853abbad0db1e9bff699976:scripts/deployment/l2/globals_optimistic_mainnet.json:generic-api-key:2 894bdea54c5b2ec7a853abbad0db1e9bff699976:scripts/deployment/l2/globals_optimistic_sepolia.json:generic-api-key:2 894bdea54c5b2ec7a853abbad0db1e9bff699976:scripts/deployment/l2/wormhole/globals_celo_mainnet.json:generic-api-key:2 -da106fa3b354dc6b8057b9585cbed1b0d4137881:scripts/deployment/l2/globals_optimistic_sepolia.json:generic-api-key:1 \ No newline at end of file +da106fa3b354dc6b8057b9585cbed1b0d4137881:scripts/deployment/l2/globals_optimistic_sepolia.json:generic-api-key:1 +d30a0b62c1d44220764e3571921d1b6d331c0142:scripts/deployment/l2/globals_base_mainnet.json:generic-api-key:1 +d30a0b62c1d44220764e3571921d1b6d331c0142:scripts/deployment/l2/globals_celo_mainnet.json:generic-api-key:1 +d30a0b62c1d44220764e3571921d1b6d331c0142:scripts/deployment/l2/globals_optimistic_mainnet.json:generic-api-key:1 +c578d645ba3fbdd0b3b4d3d61b0135f80a713870:scripts/deployment/l2/globals_base_mainnet.json:generic-api-key:1 +c578d645ba3fbdd0b3b4d3d61b0135f80a713870:scripts/deployment/l2/globals_celo_mainnet.json:generic-api-key:1 +c578d645ba3fbdd0b3b4d3d61b0135f80a713870:scripts/deployment/l2/globals_optimistic_mainnet.json:generic-api-key:1 \ No newline at end of file diff --git a/abis/bridges/optimism/L1CrossDomainMessenger.json b/abis/bridges/optimism/L1CrossDomainMessenger.json new file mode 100644 index 00000000..b8da6f20 --- /dev/null +++ b/abis/bridges/optimism/L1CrossDomainMessenger.json @@ -0,0 +1 @@ +[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"msgHash","type":"bytes32"}],"name":"FailedRelayedMessage","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"msgHash","type":"bytes32"}],"name":"RelayedMessage","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"target","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"bytes","name":"message","type":"bytes"},{"indexed":false,"internalType":"uint256","name":"messageNonce","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasLimit","type":"uint256"}],"name":"SentMessage","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"SentMessageExtension1","type":"event"},{"inputs":[],"name":"MESSAGE_VERSION","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MIN_GAS_CALLDATA_OVERHEAD","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"OTHER_MESSENGER","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PORTAL","outputs":[{"internalType":"contract OptimismPortal","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"RELAY_CALL_OVERHEAD","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"RELAY_CONSTANT_OVERHEAD","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"RELAY_GAS_CHECK_BUFFER","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"RELAY_RESERVED_GAS","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes","name":"_message","type":"bytes"},{"internalType":"uint32","name":"_minGasLimit","type":"uint32"}],"name":"baseGas","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"failedMessages","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract OptimismPortal","name":"_portal","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"messageNonce","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"portal","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_nonce","type":"uint256"},{"internalType":"address","name":"_sender","type":"address"},{"internalType":"address","name":"_target","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"},{"internalType":"uint256","name":"_minGasLimit","type":"uint256"},{"internalType":"bytes","name":"_message","type":"bytes"}],"name":"relayMessage","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"_target","type":"address"},{"internalType":"bytes","name":"_message","type":"bytes"},{"internalType":"uint32","name":"_minGasLimit","type":"uint32"}],"name":"sendMessage","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"successfulMessages","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"xDomainMessageSender","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}] diff --git a/abis/bridges/optimism/OptimismMessenger.json b/abis/bridges/optimism/OptimismMessenger.json new file mode 100644 index 00000000..39f99dc7 --- /dev/null +++ b/abis/bridges/optimism/OptimismMessenger.json @@ -0,0 +1,301 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "OptimismMessenger", + "sourceName": "contracts/bridges/OptimismMessenger.sol", + "abi": [ + { + "inputs": [ + { + "internalType": "address", + "name": "_CDMContractProxyHome", + "type": "address" + }, + { + "internalType": "address", + "name": "_sourceGovernor", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "deliveryHash", + "type": "bytes32" + } + ], + "name": "AlreadyDelivered", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expected", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "provided", + "type": "uint256" + } + ], + "name": "IncorrectDataLength", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "balance", + "type": "uint256" + } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "instance", + "type": "address" + } + ], + "name": "SelfCallOnly", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "sourceGovernor", + "type": "address" + } + ], + "name": "SourceGovernorOnly", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "sender", + "type": "bytes32" + }, + { + "internalType": "bytes32", + "name": "sourceGovernor", + "type": "bytes32" + } + ], + "name": "SourceGovernorOnly32", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "target", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "payload", + "type": "bytes" + } + ], + "name": "TargetExecFailed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "targetRelayer", + "type": "address" + } + ], + "name": "TargetRelayerOnly", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "received", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "required", + "type": "uint256" + } + ], + "name": "WrongSourceChainId", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddress", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroValue", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "FundsReceived", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sourceMessageSender", + "type": "address" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "MessageReceived", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sourceGovernor", + "type": "address" + } + ], + "name": "SourceGovernorUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "CDMContractProxyHome", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "DEFAULT_DATA_LENGTH", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newSourceGovernor", + "type": "address" + } + ], + "name": "changeSourceGovernor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "processMessageFromSource", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "sourceGovernor", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + } + ], + "bytecode": "0x60a060405234801561001057600080fd5b50604051610b91380380610b9183398101604081905261002f916100ae565b6001600160a01b038216158061004c57506001600160a01b038116155b1561006a5760405163d92e233d60e01b815260040160405180910390fd5b6001600160a01b03918216608052600080546001600160a01b031916919092161790556100e1565b80516001600160a01b03811681146100a957600080fd5b919050565b600080604083850312156100c157600080fd5b6100ca83610092565b91506100d860208401610092565b90509250929050565b608051610a816101106000396000818160b10152818161019a01528181610202015261027d0152610a816000f3fe60806040526004361061005e5760003560e01c8063e3b94a2311610043578063e3b94a2314610112578063f02fb7741461013f578063f8b4870f1461016257600080fd5b8063c84043301461009f578063d3042d2b146100fd57600080fd5b3661009a5760405134815233907f8e47b87b0ef542cdfa1659c551d88bad38aa7f452d2bbb349ab7530dfec8be8f9060200160405180910390a2005b600080fd5b3480156100ab57600080fd5b506100d37f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b61011061010b3660046107be565b610182565b005b34801561011e57600080fd5b506000546100d39073ffffffffffffffffffffffffffffffffffffffff1681565b34801561014b57600080fd5b50610154602481565b6040519081526020016100f4565b34801561016e57600080fd5b5061011061017d3660046108b2565b6103d0565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610234576040517f2f3111fa00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001660248201526044015b60405180910390fd5b60008054604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff92831693927f00000000000000000000000000000000000000000000000000000000000000001691636e296e45916004808301926020929190829003018187875af11580156102c9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102ed91906108d6565b90508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610374576040517f978c830c00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80831660048301528316602482015260440161022b565b61037d836104cb565b8173ffffffffffffffffffffffffffffffffffffffff167f3c64b439784b3c09eba93acf868463aed0e339a92920e1d8822118261dfc1a7d846040516103c39190610961565b60405180910390a2505050565b333014610411576040517f0dbc9bfc00000000000000000000000000000000000000000000000000000000815233600482015230602482015260440161022b565b73ffffffffffffffffffffffffffffffffffffffff811661045e576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117825560405190917fbbc9d5867fd60faf098cfaa8adb3402dd83501cc76385968ddbb6b2610800f8e91a250565b805160248110156105165781516040517f34c9027a00000000000000000000000000000000000000000000000000000000815261022b91602491600401918252602082015260400190565b60005b8181101561078a57828101601481015160208201516024928301519290930192909173ffffffffffffffffffffffffffffffffffffffff8316610588576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b47826bffffffffffffffffffffffff1611156105e6576040517fcf4791810000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff8316600482015247602482015260440161022b565b60008163ffffffff1667ffffffffffffffff8111156106075761060761078f565b6040519080825280601f01601f191660200182016040528015610631576020820181803683370190505b50905060005b8263ffffffff168110156106b457876106508288610974565b81518110610660576106606109b4565b602001015160f81c60f81b82828151811061067d5761067d6109b4565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600101610637565b506106c563ffffffff831686610974565b945060008473ffffffffffffffffffffffffffffffffffffffff16846bffffffffffffffffffffffff16836040516106fd91906109e3565b60006040518083038185875af1925050503d806000811461073a576040519150601f19603f3d011682016040523d82523d6000602084013e61073f565b606091505b5050905080610780578484836040517f6cfc79a500000000000000000000000000000000000000000000000000000000815260040161022b939291906109ff565b5050505050610519565b505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000602082840312156107d057600080fd5b813567ffffffffffffffff808211156107e857600080fd5b818401915084601f8301126107fc57600080fd5b81358181111561080e5761080e61078f565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156108545761085461078f565b8160405282815287602084870101111561086d57600080fd5b826020860160208301376000928101602001929092525095945050505050565b73ffffffffffffffffffffffffffffffffffffffff811681146108af57600080fd5b50565b6000602082840312156108c457600080fd5b81356108cf8161088d565b9392505050565b6000602082840312156108e857600080fd5b81516108cf8161088d565b60005b8381101561090e5781810151838201526020016108f6565b50506000910152565b6000815180845261092f8160208601602086016108f3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006108cf6020830184610917565b808201808211156109ae577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082516109f58184602087016108f3565b9190910192915050565b73ffffffffffffffffffffffffffffffffffffffff841681526bffffffffffffffffffffffff83166020820152606060408201526000610a426060830184610917565b9594505050505056fea2646970667358221220c8855bb8d138c809e71ccdac5baac500ad3deb2f38b2e82fe5572138dc23d8d064736f6c63430008170033", + "deployedBytecode": "0x60806040526004361061005e5760003560e01c8063e3b94a2311610043578063e3b94a2314610112578063f02fb7741461013f578063f8b4870f1461016257600080fd5b8063c84043301461009f578063d3042d2b146100fd57600080fd5b3661009a5760405134815233907f8e47b87b0ef542cdfa1659c551d88bad38aa7f452d2bbb349ab7530dfec8be8f9060200160405180910390a2005b600080fd5b3480156100ab57600080fd5b506100d37f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b61011061010b3660046107be565b610182565b005b34801561011e57600080fd5b506000546100d39073ffffffffffffffffffffffffffffffffffffffff1681565b34801561014b57600080fd5b50610154602481565b6040519081526020016100f4565b34801561016e57600080fd5b5061011061017d3660046108b2565b6103d0565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610234576040517f2f3111fa00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001660248201526044015b60405180910390fd5b60008054604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff92831693927f00000000000000000000000000000000000000000000000000000000000000001691636e296e45916004808301926020929190829003018187875af11580156102c9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102ed91906108d6565b90508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610374576040517f978c830c00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80831660048301528316602482015260440161022b565b61037d836104cb565b8173ffffffffffffffffffffffffffffffffffffffff167f3c64b439784b3c09eba93acf868463aed0e339a92920e1d8822118261dfc1a7d846040516103c39190610961565b60405180910390a2505050565b333014610411576040517f0dbc9bfc00000000000000000000000000000000000000000000000000000000815233600482015230602482015260440161022b565b73ffffffffffffffffffffffffffffffffffffffff811661045e576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117825560405190917fbbc9d5867fd60faf098cfaa8adb3402dd83501cc76385968ddbb6b2610800f8e91a250565b805160248110156105165781516040517f34c9027a00000000000000000000000000000000000000000000000000000000815261022b91602491600401918252602082015260400190565b60005b8181101561078a57828101601481015160208201516024928301519290930192909173ffffffffffffffffffffffffffffffffffffffff8316610588576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b47826bffffffffffffffffffffffff1611156105e6576040517fcf4791810000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff8316600482015247602482015260440161022b565b60008163ffffffff1667ffffffffffffffff8111156106075761060761078f565b6040519080825280601f01601f191660200182016040528015610631576020820181803683370190505b50905060005b8263ffffffff168110156106b457876106508288610974565b81518110610660576106606109b4565b602001015160f81c60f81b82828151811061067d5761067d6109b4565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600101610637565b506106c563ffffffff831686610974565b945060008473ffffffffffffffffffffffffffffffffffffffff16846bffffffffffffffffffffffff16836040516106fd91906109e3565b60006040518083038185875af1925050503d806000811461073a576040519150601f19603f3d011682016040523d82523d6000602084013e61073f565b606091505b5050905080610780578484836040517f6cfc79a500000000000000000000000000000000000000000000000000000000815260040161022b939291906109ff565b5050505050610519565b505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000602082840312156107d057600080fd5b813567ffffffffffffffff808211156107e857600080fd5b818401915084601f8301126107fc57600080fd5b81358181111561080e5761080e61078f565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156108545761085461078f565b8160405282815287602084870101111561086d57600080fd5b826020860160208301376000928101602001929092525095945050505050565b73ffffffffffffffffffffffffffffffffffffffff811681146108af57600080fd5b50565b6000602082840312156108c457600080fd5b81356108cf8161088d565b9392505050565b6000602082840312156108e857600080fd5b81516108cf8161088d565b60005b8381101561090e5781810151838201526020016108f6565b50506000910152565b6000815180845261092f8160208601602086016108f3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006108cf6020830184610917565b808201808211156109ae577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082516109f58184602087016108f3565b9190910192915050565b73ffffffffffffffffffffffffffffffffffffffff841681526bffffffffffffffffffffffff83166020820152606060408201526000610a426060830184610917565b9594505050505056fea2646970667358221220c8855bb8d138c809e71ccdac5baac500ad3deb2f38b2e82fe5572138dc23d8d064736f6c63430008170033", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/abis/bridges/wormhole/WormholeCore.json b/abis/bridges/wormhole/WormholeCore.json new file mode 100644 index 00000000..56df1fd3 --- /dev/null +++ b/abis/bridges/wormhole/WormholeCore.json @@ -0,0 +1 @@ +[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"previousAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newAdmin","type":"address"}],"name":"AdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"beacon","type":"address"}],"name":"BeaconUpgraded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"oldContract","type":"address"},{"indexed":true,"internalType":"address","name":"newContract","type":"address"}],"name":"ContractUpgraded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint32","name":"index","type":"uint32"}],"name":"GuardianSetAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint64","name":"sequence","type":"uint64"},{"indexed":false,"internalType":"uint32","name":"nonce","type":"uint32"},{"indexed":false,"internalType":"bytes","name":"payload","type":"bytes"},{"indexed":false,"internalType":"uint8","name":"consistencyLevel","type":"uint8"}],"name":"LogMessagePublished","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"implementation","type":"address"}],"name":"Upgraded","type":"event"},{"stateMutability":"payable","type":"fallback"},{"inputs":[],"name":"chainId","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"evmChainId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentGuardianSetIndex","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"index","type":"uint32"}],"name":"getGuardianSet","outputs":[{"components":[{"internalType":"address[]","name":"keys","type":"address[]"},{"internalType":"uint32","name":"expirationTime","type":"uint32"}],"internalType":"struct Structs.GuardianSet","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getGuardianSetExpiry","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"hash","type":"bytes32"}],"name":"governanceActionIsConsumed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"governanceChainId","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"governanceContract","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"isFork","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"impl","type":"address"}],"name":"isInitialized","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"messageFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"emitter","type":"address"}],"name":"nextSequence","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedVM","type":"bytes"}],"name":"parseAndVerifyVM","outputs":[{"components":[{"internalType":"uint8","name":"version","type":"uint8"},{"internalType":"uint32","name":"timestamp","type":"uint32"},{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint16","name":"emitterChainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"},{"internalType":"uint8","name":"consistencyLevel","type":"uint8"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"uint32","name":"guardianSetIndex","type":"uint32"},{"components":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"uint8","name":"guardianIndex","type":"uint8"}],"internalType":"struct Structs.Signature[]","name":"signatures","type":"tuple[]"},{"internalType":"bytes32","name":"hash","type":"bytes32"}],"internalType":"struct Structs.VM","name":"vm","type":"tuple"},{"internalType":"bool","name":"valid","type":"bool"},{"internalType":"string","name":"reason","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpgrade","type":"bytes"}],"name":"parseContractUpgrade","outputs":[{"components":[{"internalType":"bytes32","name":"module","type":"bytes32"},{"internalType":"uint8","name":"action","type":"uint8"},{"internalType":"uint16","name":"chain","type":"uint16"},{"internalType":"address","name":"newContract","type":"address"}],"internalType":"struct GovernanceStructs.ContractUpgrade","name":"cu","type":"tuple"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpgrade","type":"bytes"}],"name":"parseGuardianSetUpgrade","outputs":[{"components":[{"internalType":"bytes32","name":"module","type":"bytes32"},{"internalType":"uint8","name":"action","type":"uint8"},{"internalType":"uint16","name":"chain","type":"uint16"},{"components":[{"internalType":"address[]","name":"keys","type":"address[]"},{"internalType":"uint32","name":"expirationTime","type":"uint32"}],"internalType":"struct Structs.GuardianSet","name":"newGuardianSet","type":"tuple"},{"internalType":"uint32","name":"newGuardianSetIndex","type":"uint32"}],"internalType":"struct GovernanceStructs.GuardianSetUpgrade","name":"gsu","type":"tuple"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedRecoverChainId","type":"bytes"}],"name":"parseRecoverChainId","outputs":[{"components":[{"internalType":"bytes32","name":"module","type":"bytes32"},{"internalType":"uint8","name":"action","type":"uint8"},{"internalType":"uint256","name":"evmChainId","type":"uint256"},{"internalType":"uint16","name":"newChainId","type":"uint16"}],"internalType":"struct GovernanceStructs.RecoverChainId","name":"rci","type":"tuple"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedSetMessageFee","type":"bytes"}],"name":"parseSetMessageFee","outputs":[{"components":[{"internalType":"bytes32","name":"module","type":"bytes32"},{"internalType":"uint8","name":"action","type":"uint8"},{"internalType":"uint16","name":"chain","type":"uint16"},{"internalType":"uint256","name":"messageFee","type":"uint256"}],"internalType":"struct GovernanceStructs.SetMessageFee","name":"smf","type":"tuple"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedTransferFees","type":"bytes"}],"name":"parseTransferFees","outputs":[{"components":[{"internalType":"bytes32","name":"module","type":"bytes32"},{"internalType":"uint8","name":"action","type":"uint8"},{"internalType":"uint16","name":"chain","type":"uint16"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes32","name":"recipient","type":"bytes32"}],"internalType":"struct GovernanceStructs.TransferFees","name":"tf","type":"tuple"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedVM","type":"bytes"}],"name":"parseVM","outputs":[{"components":[{"internalType":"uint8","name":"version","type":"uint8"},{"internalType":"uint32","name":"timestamp","type":"uint32"},{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint16","name":"emitterChainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"},{"internalType":"uint8","name":"consistencyLevel","type":"uint8"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"uint32","name":"guardianSetIndex","type":"uint32"},{"components":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"uint8","name":"guardianIndex","type":"uint8"}],"internalType":"struct Structs.Signature[]","name":"signatures","type":"tuple[]"},{"internalType":"bytes32","name":"hash","type":"bytes32"}],"internalType":"struct Structs.VM","name":"vm","type":"tuple"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"uint8","name":"consistencyLevel","type":"uint8"}],"name":"publishMessage","outputs":[{"internalType":"uint64","name":"sequence","type":"uint64"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"numGuardians","type":"uint256"}],"name":"quorum","outputs":[{"internalType":"uint256","name":"numSignaturesRequiredForQuorum","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes","name":"_vm","type":"bytes"}],"name":"submitContractUpgrade","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"_vm","type":"bytes"}],"name":"submitNewGuardianSet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"_vm","type":"bytes"}],"name":"submitRecoverChainId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"_vm","type":"bytes"}],"name":"submitSetMessageFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"_vm","type":"bytes"}],"name":"submitTransferFees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"hash","type":"bytes32"},{"components":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"uint8","name":"guardianIndex","type":"uint8"}],"internalType":"struct Structs.Signature[]","name":"signatures","type":"tuple[]"},{"components":[{"internalType":"address[]","name":"keys","type":"address[]"},{"internalType":"uint32","name":"expirationTime","type":"uint32"}],"internalType":"struct Structs.GuardianSet","name":"guardianSet","type":"tuple"}],"name":"verifySignatures","outputs":[{"internalType":"bool","name":"valid","type":"bool"},{"internalType":"string","name":"reason","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[{"components":[{"internalType":"uint8","name":"version","type":"uint8"},{"internalType":"uint32","name":"timestamp","type":"uint32"},{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint16","name":"emitterChainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"},{"internalType":"uint8","name":"consistencyLevel","type":"uint8"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"uint32","name":"guardianSetIndex","type":"uint32"},{"components":[{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"},{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"uint8","name":"guardianIndex","type":"uint8"}],"internalType":"struct Structs.Signature[]","name":"signatures","type":"tuple[]"},{"internalType":"bytes32","name":"hash","type":"bytes32"}],"internalType":"struct Structs.VM","name":"vm","type":"tuple"}],"name":"verifyVM","outputs":[{"internalType":"bool","name":"valid","type":"bool"},{"internalType":"string","name":"reason","type":"string"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}] \ No newline at end of file diff --git a/abis/bridges/wormhole/WormholeMessenger.json b/abis/bridges/wormhole/WormholeMessenger.json new file mode 100644 index 00000000..a7a2c254 --- /dev/null +++ b/abis/bridges/wormhole/WormholeMessenger.json @@ -0,0 +1,370 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "WormholeMessenger", + "sourceName": "contracts/bridges/WormholeMessenger.sol", + "abi": [ + { + "inputs": [ + { + "internalType": "address", + "name": "_wormholeRelayer", + "type": "address" + }, + { + "internalType": "bytes32", + "name": "_sourceGovernor", + "type": "bytes32" + }, + { + "internalType": "uint16", + "name": "_sourceGovernorChainId", + "type": "uint16" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "deliveryHash", + "type": "bytes32" + } + ], + "name": "AlreadyDelivered", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "expected", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "provided", + "type": "uint256" + } + ], + "name": "IncorrectDataLength", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "balance", + "type": "uint256" + } + ], + "name": "InsufficientBalance", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "instance", + "type": "address" + } + ], + "name": "SelfCallOnly", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "sourceGovernor", + "type": "address" + } + ], + "name": "SourceGovernorOnly", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "sender", + "type": "bytes32" + }, + { + "internalType": "bytes32", + "name": "sourceGovernor", + "type": "bytes32" + } + ], + "name": "SourceGovernorOnly32", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "target", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "payload", + "type": "bytes" + } + ], + "name": "TargetExecFailed", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "internalType": "address", + "name": "targetRelayer", + "type": "address" + } + ], + "name": "TargetRelayerOnly", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "received", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "required", + "type": "uint256" + } + ], + "name": "WrongSourceChainId", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroAddress", + "type": "error" + }, + { + "inputs": [], + "name": "ZeroValue", + "type": "error" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "FundsReceived", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "bytes32", + "name": "sourceMessageSender", + "type": "bytes32" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "indexed": false, + "internalType": "bytes32", + "name": "deliveryHash", + "type": "bytes32" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "sourceChain", + "type": "uint256" + } + ], + "name": "MessageReceived", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "bytes32", + "name": "sourceGovernor", + "type": "bytes32" + } + ], + "name": "SourceGovernorUpdated", + "type": "event" + }, + { + "inputs": [], + "name": "DEFAULT_DATA_LENGTH", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "newSourceGovernor", + "type": "bytes32" + } + ], + "name": "changeSourceGovernor", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "name": "mapDeliveryHashes", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "bytes[]", + "name": "", + "type": "bytes[]" + }, + { + "internalType": "bytes32", + "name": "sourceAddress", + "type": "bytes32" + }, + { + "internalType": "uint16", + "name": "sourceChain", + "type": "uint16" + }, + { + "internalType": "bytes32", + "name": "deliveryHash", + "type": "bytes32" + } + ], + "name": "receiveWormholeMessages", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "sourceGovernor", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "sourceGovernorChainId", + "outputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "wormholeRelayer", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + } + ], + "bytecode": "0x60c060405234801561001057600080fd5b50604051610cf6380380610cf683398101604081905261002f916100a0565b6001600160a01b0383166100565760405163d92e233d60e01b815260040160405180910390fd5b811580610065575061ffff8116155b1561008357604051637c946ed760e01b815260040160405180910390fd5b6001600160a01b0390921660805260005561ffff1660a0526100f6565b6000806000606084860312156100b557600080fd5b83516001600160a01b03811681146100cc57600080fd5b60208501516040860151919450925061ffff811681146100eb57600080fd5b809150509250925092565b60805160a051610bbf6101376000396000818161010c015281816102bc015261031c0152600081816101680152818161022001526102880152610bbf6000f3fe6080604052600436106100745760003560e01c8063da25b7251161004e578063da25b72514610156578063e3b94a23146101af578063f02fb774146101d3578063fb9a487e146101e857600080fd5b8063446a9695146100b557806347059760146100fa578063529dca321461014157600080fd5b366100b05760405134815233907f8e47b87b0ef542cdfa1659c551d88bad38aa7f452d2bbb349ab7530dfec8be8f9060200160405180910390a2005b600080fd5b3480156100c157600080fd5b506100e56100d03660046107d2565b60016020526000908152604090205460ff1681565b60405190151581526020015b60405180910390f35b34801561010657600080fd5b5061012e7f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff90911681526020016100f1565b61015461014f36600461090e565b610208565b005b34801561016257600080fd5b5061018a7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f1565b3480156101bb57600080fd5b506101c560005481565b6040519081526020016100f1565b3480156101df57600080fd5b506101c5602481565b3480156101f457600080fd5b506101546102033660046107d2565b610462565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146102ba576040517f2f3111fa00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001660248201526044015b60405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168261ffff1614610349576040517fab1e308b00000000000000000000000000000000000000000000000000000000815261ffff80841660048301527f00000000000000000000000000000000000000000000000000000000000000001660248201526044016102b1565b60005483811461038f576040517fe4e8887200000000000000000000000000000000000000000000000000000000815260048101859052602481018290526044016102b1565b60008281526001602052604090205460ff16156103db576040517f56bc34a1000000000000000000000000000000000000000000000000000000008152600481018390526024016102b1565b600082815260016020819052604090912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016909117905561041e8661050e565b807fd8cd153bfe87c1532b57496df668459b04cf5517c686a785817278fae362daac87848660405161045293929190610a85565b60405180910390a2505050505050565b3330146104a3576040517f0dbc9bfc0000000000000000000000000000000000000000000000000000000081523360048201523060248201526044016102b1565b60008190036104de576040517f7c946ed700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815560405182917f5a44f84b9c7ddf51c2fc1ff0026700203679762f67a7425804d9d9801d8d61e691a250565b805160248110156105595781516040517f34c9027a0000000000000000000000000000000000000000000000000000000081526102b191602491600401918252602082015260400190565b60005b818110156107cd57828101601481015160208201516024928301519290930192909173ffffffffffffffffffffffffffffffffffffffff83166105cb576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b47826bffffffffffffffffffffffff161115610629576040517fcf4791810000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff831660048201524760248201526044016102b1565b60008163ffffffff1667ffffffffffffffff81111561064a5761064a6107eb565b6040519080825280601f01601f191660200182016040528015610674576020820181803683370190505b50905060005b8263ffffffff168110156106f757876106938288610ab2565b815181106106a3576106a3610af2565b602001015160f81c60f81b8282815181106106c0576106c0610af2565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535060010161067a565b5061070863ffffffff831686610ab2565b945060008473ffffffffffffffffffffffffffffffffffffffff16846bffffffffffffffffffffffff16836040516107409190610b21565b60006040518083038185875af1925050503d806000811461077d576040519150601f19603f3d011682016040523d82523d6000602084013e610782565b606091505b50509050806107c3578484836040517f6cfc79a50000000000000000000000000000000000000000000000000000000081526004016102b193929190610b3d565b505050505061055c565b505050565b6000602082840312156107e457600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610861576108616107eb565b604052919050565b600082601f83011261087a57600080fd5b813567ffffffffffffffff811115610894576108946107eb565b6108c560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161081a565b8181528460208386010111156108da57600080fd5b816020850160208301376000918101602001919091529392505050565b803561ffff8116811461090957600080fd5b919050565b600080600080600060a0868803121561092657600080fd5b853567ffffffffffffffff8082111561093e57600080fd5b61094a89838a01610869565b965060209150818801358181111561096157600080fd5b8801601f81018a1361097257600080fd5b803582811115610984576109846107eb565b8060051b61099385820161081a565b918252828101850191858101908d8411156109ad57600080fd5b86850192505b838310156109e9578235868111156109cb5760008081fd5b6109d98f8983890101610869565b83525091860191908601906109b3565b809a505050505050505060408601359250610a06606087016108f7565b949793965091946080013592915050565b60005b83811015610a32578181015183820152602001610a1a565b50506000910152565b60008151808452610a53816020860160208601610a17565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b606081526000610a986060830186610a3b565b905083602083015261ffff83166040830152949350505050565b80820180821115610aec577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008251610b33818460208701610a17565b9190910192915050565b73ffffffffffffffffffffffffffffffffffffffff841681526bffffffffffffffffffffffff83166020820152606060408201526000610b806060830184610a3b565b9594505050505056fea26469706673582212204db311bcff4340e7ff2b45c2409038e5602e521f704ea4b4fc66aa64f9a069c664736f6c63430008170033", + "deployedBytecode": "0x6080604052600436106100745760003560e01c8063da25b7251161004e578063da25b72514610156578063e3b94a23146101af578063f02fb774146101d3578063fb9a487e146101e857600080fd5b8063446a9695146100b557806347059760146100fa578063529dca321461014157600080fd5b366100b05760405134815233907f8e47b87b0ef542cdfa1659c551d88bad38aa7f452d2bbb349ab7530dfec8be8f9060200160405180910390a2005b600080fd5b3480156100c157600080fd5b506100e56100d03660046107d2565b60016020526000908152604090205460ff1681565b60405190151581526020015b60405180910390f35b34801561010657600080fd5b5061012e7f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff90911681526020016100f1565b61015461014f36600461090e565b610208565b005b34801561016257600080fd5b5061018a7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f1565b3480156101bb57600080fd5b506101c560005481565b6040519081526020016100f1565b3480156101df57600080fd5b506101c5602481565b3480156101f457600080fd5b506101546102033660046107d2565b610462565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146102ba576040517f2f3111fa00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001660248201526044015b60405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168261ffff1614610349576040517fab1e308b00000000000000000000000000000000000000000000000000000000815261ffff80841660048301527f00000000000000000000000000000000000000000000000000000000000000001660248201526044016102b1565b60005483811461038f576040517fe4e8887200000000000000000000000000000000000000000000000000000000815260048101859052602481018290526044016102b1565b60008281526001602052604090205460ff16156103db576040517f56bc34a1000000000000000000000000000000000000000000000000000000008152600481018390526024016102b1565b600082815260016020819052604090912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016909117905561041e8661050e565b807fd8cd153bfe87c1532b57496df668459b04cf5517c686a785817278fae362daac87848660405161045293929190610a85565b60405180910390a2505050505050565b3330146104a3576040517f0dbc9bfc0000000000000000000000000000000000000000000000000000000081523360048201523060248201526044016102b1565b60008190036104de576040517f7c946ed700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815560405182917f5a44f84b9c7ddf51c2fc1ff0026700203679762f67a7425804d9d9801d8d61e691a250565b805160248110156105595781516040517f34c9027a0000000000000000000000000000000000000000000000000000000081526102b191602491600401918252602082015260400190565b60005b818110156107cd57828101601481015160208201516024928301519290930192909173ffffffffffffffffffffffffffffffffffffffff83166105cb576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b47826bffffffffffffffffffffffff161115610629576040517fcf4791810000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff831660048201524760248201526044016102b1565b60008163ffffffff1667ffffffffffffffff81111561064a5761064a6107eb565b6040519080825280601f01601f191660200182016040528015610674576020820181803683370190505b50905060005b8263ffffffff168110156106f757876106938288610ab2565b815181106106a3576106a3610af2565b602001015160f81c60f81b8282815181106106c0576106c0610af2565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535060010161067a565b5061070863ffffffff831686610ab2565b945060008473ffffffffffffffffffffffffffffffffffffffff16846bffffffffffffffffffffffff16836040516107409190610b21565b60006040518083038185875af1925050503d806000811461077d576040519150601f19603f3d011682016040523d82523d6000602084013e610782565b606091505b50509050806107c3578484836040517f6cfc79a50000000000000000000000000000000000000000000000000000000081526004016102b193929190610b3d565b505050505061055c565b505050565b6000602082840312156107e457600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610861576108616107eb565b604052919050565b600082601f83011261087a57600080fd5b813567ffffffffffffffff811115610894576108946107eb565b6108c560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161081a565b8181528460208386010111156108da57600080fd5b816020850160208301376000918101602001919091529392505050565b803561ffff8116811461090957600080fd5b919050565b600080600080600060a0868803121561092657600080fd5b853567ffffffffffffffff8082111561093e57600080fd5b61094a89838a01610869565b965060209150818801358181111561096157600080fd5b8801601f81018a1361097257600080fd5b803582811115610984576109846107eb565b8060051b61099385820161081a565b918252828101850191858101908d8411156109ad57600080fd5b86850192505b838310156109e9578235868111156109cb5760008081fd5b6109d98f8983890101610869565b83525091860191908601906109b3565b809a505050505050505060408601359250610a06606087016108f7565b949793965091946080013592915050565b60005b83811015610a32578181015183820152602001610a1a565b50506000910152565b60008151808452610a53816020860160208601610a17565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b606081526000610a986060830186610a3b565b905083602083015261ffff83166040830152949350505050565b80820180821115610aec577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008251610b33818460208701610a17565b9190910192915050565b73ffffffffffffffffffffffffffffffffffffffff841681526bffffffffffffffffffffffff83166020820152606060408201526000610b806060830184610a3b565b9594505050505056fea26469706673582212204db311bcff4340e7ff2b45c2409038e5602e521f704ea4b4fc66aa64f9a069c664736f6c63430008170033", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/abis/bridges/wormhole/WormholeRelayer.json b/abis/bridges/wormhole/WormholeRelayer.json new file mode 100644 index 00000000..02886ea1 --- /dev/null +++ b/abis/bridges/wormhole/WormholeRelayer.json @@ -0,0 +1 @@ +[{"inputs":[{"internalType":"address","name":"wormhole","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes","name":"failure","type":"bytes"}],"name":"ContractUpgradeFailed","type":"error"},{"inputs":[],"name":"DeliveryProviderCannotReceivePayment","type":"error"},{"inputs":[{"internalType":"uint8","name":"keyType","type":"uint8"}],"name":"DeliveryProviderDoesNotSupportMessageKeyType","type":"error"},{"inputs":[{"internalType":"address","name":"relayer","type":"address"},{"internalType":"uint16","name":"chainId","type":"uint16"}],"name":"DeliveryProviderDoesNotSupportTargetChain","type":"error"},{"inputs":[{"internalType":"bytes32","name":"hash","type":"bytes32"}],"name":"GovernanceActionAlreadyConsumed","type":"error"},{"inputs":[{"internalType":"LocalNative","name":"msgValue","type":"uint256"},{"internalType":"LocalNative","name":"minimum","type":"uint256"}],"name":"InsufficientRelayerFunds","type":"error"},{"inputs":[{"internalType":"bytes32","name":"defaultDeliveryProvider","type":"bytes32"}],"name":"InvalidDefaultDeliveryProvider","type":"error"},{"inputs":[{"internalType":"string","name":"reason","type":"string"}],"name":"InvalidDeliveryVaa","type":"error"},{"inputs":[{"internalType":"bytes32","name":"emitter","type":"bytes32"},{"internalType":"bytes32","name":"registered","type":"bytes32"},{"internalType":"uint16","name":"chainId","type":"uint16"}],"name":"InvalidEmitter","type":"error"},{"inputs":[],"name":"InvalidFork","type":"error"},{"inputs":[{"internalType":"uint16","name":"parsed","type":"uint16"},{"internalType":"uint16","name":"expected","type":"uint16"}],"name":"InvalidGovernanceChainId","type":"error"},{"inputs":[{"internalType":"bytes32","name":"parsed","type":"bytes32"},{"internalType":"bytes32","name":"expected","type":"bytes32"}],"name":"InvalidGovernanceContract","type":"error"},{"inputs":[{"internalType":"string","name":"reason","type":"string"}],"name":"InvalidGovernanceVM","type":"error"},{"inputs":[{"internalType":"LocalNative","name":"msgValue","type":"uint256"},{"internalType":"LocalNative","name":"totalFee","type":"uint256"}],"name":"InvalidMsgValue","type":"error"},{"inputs":[],"name":"InvalidOverrideGasLimit","type":"error"},{"inputs":[],"name":"InvalidOverrideReceiverValue","type":"error"},{"inputs":[{"internalType":"uint8","name":"parsed","type":"uint8"},{"internalType":"uint8","name":"expected","type":"uint8"}],"name":"InvalidPayloadAction","type":"error"},{"inputs":[{"internalType":"uint16","name":"parsed","type":"uint16"},{"internalType":"uint16","name":"expected","type":"uint16"}],"name":"InvalidPayloadChainId","type":"error"},{"inputs":[{"internalType":"uint8","name":"parsed","type":"uint8"},{"internalType":"uint8","name":"expected","type":"uint8"}],"name":"InvalidPayloadId","type":"error"},{"inputs":[{"internalType":"uint256","name":"received","type":"uint256"},{"internalType":"uint256","name":"expected","type":"uint256"}],"name":"InvalidPayloadLength","type":"error"},{"inputs":[{"internalType":"bytes32","name":"parsed","type":"bytes32"},{"internalType":"bytes32","name":"expected","type":"bytes32"}],"name":"InvalidPayloadModule","type":"error"},{"inputs":[{"internalType":"uint256","name":"keys","type":"uint256"},{"internalType":"uint256","name":"vaas","type":"uint256"}],"name":"MessageKeysLengthDoesNotMatchMessagesLength","type":"error"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"NotAnEvmAddress","type":"error"},{"inputs":[{"internalType":"address","name":"msgSender","type":"address"},{"internalType":"address","name":"lockedBy","type":"address"}],"name":"ReentrantDelivery","type":"error"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"}],"name":"TargetChainIsNotThisChain","type":"error"},{"inputs":[{"internalType":"uint256","name":"numMessageKeys","type":"uint256"}],"name":"TooManyMessageKeys","type":"error"},{"inputs":[{"internalType":"uint8","name":"version","type":"uint8"},{"internalType":"uint8","name":"expectedVersion","type":"uint8"}],"name":"UnexpectedExecutionInfoVersion","type":"error"},{"inputs":[{"internalType":"uint8","name":"index","type":"uint8"}],"name":"VaaKeysDoNotMatchVaas","type":"error"},{"inputs":[{"internalType":"uint8","name":"instructionVersion","type":"uint8"},{"internalType":"uint8","name":"overrideVersion","type":"uint8"}],"name":"VersionMismatchOverride","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"previousAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newAdmin","type":"address"}],"name":"AdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"beacon","type":"address"}],"name":"BeaconUpgraded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"oldContract","type":"address"},{"indexed":true,"internalType":"address","name":"newContract","type":"address"}],"name":"ContractUpgraded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"recipientContract","type":"address"},{"indexed":true,"internalType":"uint16","name":"sourceChain","type":"uint16"},{"indexed":true,"internalType":"uint64","name":"sequence","type":"uint64"},{"indexed":false,"internalType":"bytes32","name":"deliveryVaaHash","type":"bytes32"},{"indexed":false,"internalType":"enum IWormholeRelayerDelivery.DeliveryStatus","name":"status","type":"uint8"},{"indexed":false,"internalType":"Gas","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"enum IWormholeRelayerDelivery.RefundStatus","name":"refundStatus","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"additionalStatusInfo","type":"bytes"},{"indexed":false,"internalType":"bytes","name":"overridesInfo","type":"bytes"}],"name":"Delivery","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint64","name":"sequence","type":"uint64"},{"indexed":false,"internalType":"LocalNative","name":"deliveryQuote","type":"uint256"},{"indexed":false,"internalType":"LocalNative","name":"paymentForExtraReceiverValue","type":"uint256"}],"name":"SendEvent","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"implementation","type":"address"}],"name":"Upgraded","type":"event"},{"inputs":[],"name":"checkAndExecuteUpgradeMigration","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes[]","name":"encodedVMs","type":"bytes[]"},{"internalType":"bytes","name":"encodedDeliveryVAA","type":"bytes"},{"internalType":"address payable","name":"relayerRefundAddress","type":"address"},{"internalType":"bytes","name":"deliveryOverrides","type":"bytes"}],"name":"deliver","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"deliveryHash","type":"bytes32"}],"name":"deliveryAttempted","outputs":[{"internalType":"bool","name":"attempted","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"deliveryHash","type":"bytes32"}],"name":"deliveryFailureBlock","outputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"deliveryHash","type":"bytes32"}],"name":"deliverySuccessBlock","outputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"bytes32","name":"targetAddress","type":"bytes32"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"LocalNative","name":"","type":"uint256"},{"internalType":"bytes","name":"encodedExecutionParameters","type":"bytes"},{"internalType":"uint16","name":"refundChain","type":"uint16"},{"internalType":"bytes32","name":"refundAddress","type":"bytes32"},{"internalType":"address","name":"deliveryProviderAddress","type":"address"},{"components":[{"internalType":"uint16","name":"chainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"}],"internalType":"struct VaaKey[]","name":"vaaKeys","type":"tuple[]"},{"internalType":"uint8","name":"consistencyLevel","type":"uint8"}],"name":"forward","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"address","name":"targetAddress","type":"address"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"Gas","name":"gasLimit","type":"uint256"}],"name":"forwardPayloadToEvm","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"address","name":"targetAddress","type":"address"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"LocalNative","name":"paymentForExtraReceiverValue","type":"uint256"},{"internalType":"Gas","name":"gasLimit","type":"uint256"},{"internalType":"uint16","name":"refundChain","type":"uint16"},{"internalType":"address","name":"refundAddress","type":"address"},{"internalType":"address","name":"deliveryProviderAddress","type":"address"},{"components":[{"internalType":"uint16","name":"chainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"}],"internalType":"struct VaaKey[]","name":"vaaKeys","type":"tuple[]"},{"internalType":"uint8","name":"consistencyLevel","type":"uint8"}],"name":"forwardToEvm","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"address","name":"targetAddress","type":"address"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"Gas","name":"gasLimit","type":"uint256"},{"components":[{"internalType":"uint16","name":"chainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"}],"internalType":"struct VaaKey[]","name":"vaaKeys","type":"tuple[]"}],"name":"forwardVaasToEvm","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"getDefaultDeliveryProvider","outputs":[{"internalType":"address","name":"deliveryProvider","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"chainId","type":"uint16"}],"name":"getRegisteredWormholeRelayerContract","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"defaultDeliveryProvider","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"bytes","name":"encodedExecutionParameters","type":"bytes"},{"internalType":"address","name":"deliveryProviderAddress","type":"address"}],"name":"quoteDeliveryPrice","outputs":[{"internalType":"LocalNative","name":"nativePriceQuote","type":"uint256"},{"internalType":"bytes","name":"encodedExecutionInfo","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"Gas","name":"gasLimit","type":"uint256"},{"internalType":"address","name":"deliveryProviderAddress","type":"address"}],"name":"quoteEVMDeliveryPrice","outputs":[{"internalType":"LocalNative","name":"nativePriceQuote","type":"uint256"},{"internalType":"GasPrice","name":"targetChainRefundPerGasUnused","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"Gas","name":"gasLimit","type":"uint256"}],"name":"quoteEVMDeliveryPrice","outputs":[{"internalType":"LocalNative","name":"nativePriceQuote","type":"uint256"},{"internalType":"GasPrice","name":"targetChainRefundPerGasUnused","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"LocalNative","name":"currentChainAmount","type":"uint256"},{"internalType":"address","name":"deliveryProviderAddress","type":"address"}],"name":"quoteNativeForChain","outputs":[{"internalType":"TargetNative","name":"targetChainAmount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedVm","type":"bytes"}],"name":"registerWormholeRelayerContract","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint16","name":"chainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"}],"internalType":"struct VaaKey","name":"deliveryVaaKey","type":"tuple"},{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"TargetNative","name":"newReceiverValue","type":"uint256"},{"internalType":"bytes","name":"newEncodedExecutionParameters","type":"bytes"},{"internalType":"address","name":"newDeliveryProviderAddress","type":"address"}],"name":"resend","outputs":[{"internalType":"uint64","name":"sequence","type":"uint64"}],"stateMutability":"payable","type":"function"},{"inputs":[{"components":[{"internalType":"uint16","name":"chainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"}],"internalType":"struct VaaKey","name":"deliveryVaaKey","type":"tuple"},{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"TargetNative","name":"newReceiverValue","type":"uint256"},{"internalType":"Gas","name":"newGasLimit","type":"uint256"},{"internalType":"address","name":"newDeliveryProviderAddress","type":"address"}],"name":"resendToEvm","outputs":[{"internalType":"uint64","name":"sequence","type":"uint64"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"bytes32","name":"targetAddress","type":"bytes32"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"LocalNative","name":"paymentForExtraReceiverValue","type":"uint256"},{"internalType":"bytes","name":"encodedExecutionParameters","type":"bytes"},{"internalType":"uint16","name":"refundChain","type":"uint16"},{"internalType":"bytes32","name":"refundAddress","type":"bytes32"},{"internalType":"address","name":"deliveryProviderAddress","type":"address"},{"components":[{"internalType":"uint16","name":"chainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"}],"internalType":"struct VaaKey[]","name":"vaaKeys","type":"tuple[]"},{"internalType":"uint8","name":"consistencyLevel","type":"uint8"}],"name":"send","outputs":[{"internalType":"uint64","name":"sequence","type":"uint64"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"bytes32","name":"targetAddress","type":"bytes32"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"LocalNative","name":"paymentForExtraReceiverValue","type":"uint256"},{"internalType":"bytes","name":"encodedExecutionParameters","type":"bytes"},{"internalType":"uint16","name":"refundChain","type":"uint16"},{"internalType":"bytes32","name":"refundAddress","type":"bytes32"},{"internalType":"address","name":"deliveryProviderAddress","type":"address"},{"components":[{"internalType":"uint8","name":"keyType","type":"uint8"},{"internalType":"bytes","name":"encodedKey","type":"bytes"}],"internalType":"struct MessageKey[]","name":"messageKeys","type":"tuple[]"},{"internalType":"uint8","name":"consistencyLevel","type":"uint8"}],"name":"send","outputs":[{"internalType":"uint64","name":"sequence","type":"uint64"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"address","name":"targetAddress","type":"address"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"Gas","name":"gasLimit","type":"uint256"},{"internalType":"uint16","name":"refundChain","type":"uint16"},{"internalType":"address","name":"refundAddress","type":"address"}],"name":"sendPayloadToEvm","outputs":[{"internalType":"uint64","name":"sequence","type":"uint64"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"address","name":"targetAddress","type":"address"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"Gas","name":"gasLimit","type":"uint256"}],"name":"sendPayloadToEvm","outputs":[{"internalType":"uint64","name":"sequence","type":"uint64"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"address","name":"targetAddress","type":"address"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"LocalNative","name":"paymentForExtraReceiverValue","type":"uint256"},{"internalType":"Gas","name":"gasLimit","type":"uint256"},{"internalType":"uint16","name":"refundChain","type":"uint16"},{"internalType":"address","name":"refundAddress","type":"address"},{"internalType":"address","name":"deliveryProviderAddress","type":"address"},{"components":[{"internalType":"uint16","name":"chainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"}],"internalType":"struct VaaKey[]","name":"vaaKeys","type":"tuple[]"},{"internalType":"uint8","name":"consistencyLevel","type":"uint8"}],"name":"sendToEvm","outputs":[{"internalType":"uint64","name":"sequence","type":"uint64"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"address","name":"targetAddress","type":"address"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"LocalNative","name":"paymentForExtraReceiverValue","type":"uint256"},{"internalType":"Gas","name":"gasLimit","type":"uint256"},{"internalType":"uint16","name":"refundChain","type":"uint16"},{"internalType":"address","name":"refundAddress","type":"address"},{"internalType":"address","name":"deliveryProviderAddress","type":"address"},{"components":[{"internalType":"uint8","name":"keyType","type":"uint8"},{"internalType":"bytes","name":"encodedKey","type":"bytes"}],"internalType":"struct MessageKey[]","name":"messageKeys","type":"tuple[]"},{"internalType":"uint8","name":"consistencyLevel","type":"uint8"}],"name":"sendToEvm","outputs":[{"internalType":"uint64","name":"sequence","type":"uint64"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"address","name":"targetAddress","type":"address"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"Gas","name":"gasLimit","type":"uint256"},{"components":[{"internalType":"uint16","name":"chainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"}],"internalType":"struct VaaKey[]","name":"vaaKeys","type":"tuple[]"}],"name":"sendVaasToEvm","outputs":[{"internalType":"uint64","name":"sequence","type":"uint64"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"targetChain","type":"uint16"},{"internalType":"address","name":"targetAddress","type":"address"},{"internalType":"bytes","name":"payload","type":"bytes"},{"internalType":"TargetNative","name":"receiverValue","type":"uint256"},{"internalType":"Gas","name":"gasLimit","type":"uint256"},{"components":[{"internalType":"uint16","name":"chainId","type":"uint16"},{"internalType":"bytes32","name":"emitterAddress","type":"bytes32"},{"internalType":"uint64","name":"sequence","type":"uint64"}],"internalType":"struct VaaKey[]","name":"vaaKeys","type":"tuple[]"},{"internalType":"uint16","name":"refundChain","type":"uint16"},{"internalType":"address","name":"refundAddress","type":"address"}],"name":"sendVaasToEvm","outputs":[{"internalType":"uint64","name":"sequence","type":"uint64"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedVm","type":"bytes"}],"name":"setDefaultDeliveryProvider","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedVm","type":"bytes"}],"name":"submitContractUpgrade","outputs":[],"stateMutability":"nonpayable","type":"function"}] diff --git a/docs/configuration.json b/docs/configuration.json index 20739823..c3b0ac37 100644 --- a/docs/configuration.json +++ b/docs/configuration.json @@ -249,8 +249,8 @@ }, { "name": "GnosisSafeMultisig", - "artifact": "abis/0.8.23/GnosisSafeMultisig.json", - "address": "0xE43d4F4103b623B61E095E8bEA34e1bc8979e168" + "artifact": "abis/0.8.28/GnosisSafeMultisig.json", + "address": "0x5953f21495BD9aF1D78e87bb42AcCAA55C1e896C" }, { "name": "GnosisSafeSameAddressMultisig", @@ -300,8 +300,8 @@ }, { "name": "GnosisSafeMultisig", - "artifact": "abis/0.8.23/GnosisSafeMultisig.json", - "address": "0xBb7e1D6Cb6F243D6bdE81CE92a9f2aFF7Fbe7eac" + "artifact": "abis/0.8.28/GnosisSafeMultisig.json", + "address": "0x22bE6fDcd3e29851B29b512F714C328A00A96B83" }, { "name": "GnosisSafeSameAddressMultisig", diff --git a/scripts/deployment/l2/globals_base_mainnet.json b/scripts/deployment/l2/globals_base_mainnet.json index c1ac5312..d7530398 100644 --- a/scripts/deployment/l2/globals_base_mainnet.json +++ b/scripts/deployment/l2/globals_base_mainnet.json @@ -1 +1 @@ -{"contractVerification":true,"useLedger":true,"derivationPath":"m/44'/60'/2'/0/0","providerName":"base","networkURL":"https://mainnet.base.org","gasPriceInGwei":"2","gnosisSafeAddress":"0xd9Db270c1B5E3Bd161E8c8503c55cEABeE709552","gnosisSafeProxyFactoryAddress":"0xa6B71E26C5e0845f74c812102Ca7114b6a896AB2","baseURI":"https://gateway.autonolas.tech/ipfs/","serviceRegistryName":"Service Registry L2","serviceRegistrySymbol":"AUTONOLAS-SERVICE-L2-V1","bridgeMediatorAddress":"0xE49CB081e8d96920C38aA7AB90cb0294ab4Bc8EA","olasAddress":"0x54330d28ca3357F294334BDC454a032e7f353416","multisigProxyHash130":"0xb89c1b3bdf2cf8827818646bce9a8f6e372885f8c55e5c07acbd307cb133b000","serviceRegistryAddress":"0x3C1fF68f5aa342D296d4DEe4Bb1cACCA912D95fE","operatorWhitelistAddress":"0x3d77596beb0f130a4415df3D2D8232B3d3D31e44","serviceRegistryTokenUtilityAddress":"0x34C895f302D0b5cf52ec0Edd3945321EB0f83dd5","serviceManagerTokenAddress":"0x63e66d7ad413C01A7b49C7FF4e3Bb765C4E4bd1b","gnosisSafeMultisigImplementationAddress":"0xBb7e1D6Cb6F243D6bdE81CE92a9f2aFF7Fbe7eac","gnosisSafeSameAddressMultisigImplementationAddress":"0xFbBEc0C8b13B38a9aC0499694A69a10204c5E2aB","stakingTokenAddress":"0xEB5638eefE289691EcE01943f768EDBF96258a80","stakingNativeTokenAddress":"","minStakingDepositLimit":"10000000000000000000000","timeForEmissionsLimit":"2592000","numServicesLimit":"100","apyLimit":"3000000000000000000","stakingVerifierAddress":"0x10c5525F77F13b28f42c5626240c001c2D57CAd4","stakingFactoryAddress":"0x1cEe30D08943EB58EFF84DD1AB44a6ee6FEff63a","L1CrossDomainMessengerProxyAddress":"0xE49CB081e8d96920C38aA7AB90cb0294ab4Bc8EA"} \ No newline at end of file +{"contractVerification":true,"useLedger":true,"derivationPath":"m/44'/60'/2'/0/0","providerName":"base","networkURL":"https://mainnet.base.org","gasPriceInGwei":"2","gnosisSafeAddress":"0xd9Db270c1B5E3Bd161E8c8503c55cEABeE709552","gnosisSafeProxyFactoryAddress":"0xa6B71E26C5e0845f74c812102Ca7114b6a896AB2","baseURI":"https://gateway.autonolas.tech/ipfs/","serviceRegistryName":"Service Registry L2","serviceRegistrySymbol":"AUTONOLAS-SERVICE-L2-V1","bridgeMediatorAddress":"0xE49CB081e8d96920C38aA7AB90cb0294ab4Bc8EA","olasAddress":"0x54330d28ca3357F294334BDC454a032e7f353416","multisigProxyHash130":"0xb89c1b3bdf2cf8827818646bce9a8f6e372885f8c55e5c07acbd307cb133b000","serviceRegistryAddress":"0x3C1fF68f5aa342D296d4DEe4Bb1cACCA912D95fE","operatorWhitelistAddress":"0x3d77596beb0f130a4415df3D2D8232B3d3D31e44","serviceRegistryTokenUtilityAddress":"0x34C895f302D0b5cf52ec0Edd3945321EB0f83dd5","serviceManagerTokenAddress":"0x63e66d7ad413C01A7b49C7FF4e3Bb765C4E4bd1b","gnosisSafeMultisigImplementationAddress":"0x22bE6fDcd3e29851B29b512F714C328A00A96B83","gnosisSafeSameAddressMultisigImplementationAddress":"0xFbBEc0C8b13B38a9aC0499694A69a10204c5E2aB","stakingTokenAddress":"0xEB5638eefE289691EcE01943f768EDBF96258a80","stakingNativeTokenAddress":"","minStakingDepositLimit":"10000000000000000000000","timeForEmissionsLimit":"2592000","numServicesLimit":"100","apyLimit":"3000000000000000000","stakingVerifierAddress":"0x10c5525F77F13b28f42c5626240c001c2D57CAd4","stakingFactoryAddress":"0x1cEe30D08943EB58EFF84DD1AB44a6ee6FEff63a","L1CrossDomainMessengerProxyAddress":"0xE49CB081e8d96920C38aA7AB90cb0294ab4Bc8EA"} \ No newline at end of file diff --git a/scripts/deployment/l2/globals_celo_mainnet.json b/scripts/deployment/l2/globals_celo_mainnet.json index aa1d6631..36a8f15d 100644 --- a/scripts/deployment/l2/globals_celo_mainnet.json +++ b/scripts/deployment/l2/globals_celo_mainnet.json @@ -1 +1 @@ -{"contractVerification":true,"useLedger":true,"derivationPath":"m/44'/60'/2'/0/0","providerName":"celo","networkURL":"https://forno.celo.org","gasPriceInGwei":"10","gnosisSafeAddress":"0xd9Db270c1B5E3Bd161E8c8503c55cEABeE709552","gnosisSafeProxyFactoryAddress":"0xa6B71E26C5e0845f74c812102Ca7114b6a896AB2","baseURI":"https://gateway.autonolas.tech/ipfs/","serviceRegistryName":"Service Registry L2","serviceRegistrySymbol":"AUTONOLAS-SERVICE-L2-V1","bridgeMediatorAddress":"0x397125902ED2cA2d42104F621f448A2cE1bC8Fb7","olasAddress":"0xaCFfAe8e57Ec6E394Eb1b41939A8CF7892DbDc51","multisigProxyHash130":"0xb89c1b3bdf2cf8827818646bce9a8f6e372885f8c55e5c07acbd307cb133b000","serviceRegistryAddress":"0xE3607b00E75f6405248323A9417ff6b39B244b50","operatorWhitelistAddress":"0x3C1fF68f5aa342D296d4DEe4Bb1cACCA912D95fE","serviceRegistryTokenUtilityAddress":"0x3d77596beb0f130a4415df3D2D8232B3d3D31e44","serviceManagerTokenAddress":"0x34C895f302D0b5cf52ec0Edd3945321EB0f83dd5","gnosisSafeMultisigImplementationAddress":"0x63e66d7ad413C01A7b49C7FF4e3Bb765C4E4bd1b","gnosisSafeSameAddressMultisigImplementationAddress":"0xBb7e1D6Cb6F243D6bdE81CE92a9f2aFF7Fbe7eac","stakingTokenAddress":"0xe1E1B286EbE95b39F785d8069f2248ae9C41b7a9","stakingNativeTokenAddress":"","minStakingDepositLimit":"10000000000000000000000","timeForEmissionsLimit":"2592000","numServicesLimit":"100","apyLimit":"3000000000000000000","stakingVerifierAddress":"0xc40C79C275F3fA1F3f4c723755C81ED2D53A8D81","stakingFactoryAddress":"0x1c2cD884127b080F940b7546c1e9aaf525b1FA55","wormholeL1MessageRelayerAddress":"0x27428DD2d3DD32A4D7f7C497eAaa23130d894911","wormholeMessengerAddress":"0x397125902ED2cA2d42104F621f448A2cE1bC8Fb7"} \ No newline at end of file +{"contractVerification":true,"useLedger":true,"derivationPath":"m/44'/60'/2'/0/0","providerName":"celo","networkURL":"https://forno.celo.org","gasPriceInGwei":"10","gnosisSafeAddress":"0xd9Db270c1B5E3Bd161E8c8503c55cEABeE709552","gnosisSafeProxyFactoryAddress":"0xa6B71E26C5e0845f74c812102Ca7114b6a896AB2","baseURI":"https://gateway.autonolas.tech/ipfs/","serviceRegistryName":"Service Registry L2","serviceRegistrySymbol":"AUTONOLAS-SERVICE-L2-V1","bridgeMediatorAddress":"0x397125902ED2cA2d42104F621f448A2cE1bC8Fb7","olasAddress":"0xaCFfAe8e57Ec6E394Eb1b41939A8CF7892DbDc51","multisigProxyHash130":"0xb89c1b3bdf2cf8827818646bce9a8f6e372885f8c55e5c07acbd307cb133b000","serviceRegistryAddress":"0xE3607b00E75f6405248323A9417ff6b39B244b50","operatorWhitelistAddress":"0x3C1fF68f5aa342D296d4DEe4Bb1cACCA912D95fE","serviceRegistryTokenUtilityAddress":"0x3d77596beb0f130a4415df3D2D8232B3d3D31e44","serviceManagerTokenAddress":"0x34C895f302D0b5cf52ec0Edd3945321EB0f83dd5","gnosisSafeMultisigImplementationAddress":"0xD421f433e36465B3e558B1121F584ac09Fc33DF8","gnosisSafeSameAddressMultisigImplementationAddress":"0xBb7e1D6Cb6F243D6bdE81CE92a9f2aFF7Fbe7eac","stakingTokenAddress":"0xe1E1B286EbE95b39F785d8069f2248ae9C41b7a9","stakingNativeTokenAddress":"","minStakingDepositLimit":"10000000000000000000000","timeForEmissionsLimit":"2592000","numServicesLimit":"100","apyLimit":"3000000000000000000","stakingVerifierAddress":"0xc40C79C275F3fA1F3f4c723755C81ED2D53A8D81","stakingFactoryAddress":"0x1c2cD884127b080F940b7546c1e9aaf525b1FA55","wormholeL1MessageRelayerAddress":"0x27428DD2d3DD32A4D7f7C497eAaa23130d894911","wormholeMessengerAddress":"0x397125902ED2cA2d42104F621f448A2cE1bC8Fb7"} \ No newline at end of file diff --git a/scripts/deployment/l2/globals_optimistic_mainnet.json b/scripts/deployment/l2/globals_optimistic_mainnet.json index 4b16e7df..ffbb6f91 100644 --- a/scripts/deployment/l2/globals_optimistic_mainnet.json +++ b/scripts/deployment/l2/globals_optimistic_mainnet.json @@ -1 +1 @@ -{"contractVerification":true,"useLedger":true,"derivationPath":"m/44'/60'/2'/0/0","providerName":"optimistic","networkURL":"https://mainnet.optimism.io","gasPriceInGwei":"2","gnosisSafeAddress":"0xd9Db270c1B5E3Bd161E8c8503c55cEABeE709552","gnosisSafeProxyFactoryAddress":"0xa6B71E26C5e0845f74c812102Ca7114b6a896AB2","baseURI":"https://gateway.autonolas.tech/ipfs/","serviceRegistryName":"Service Registry L2","serviceRegistrySymbol":"AUTONOLAS-SERVICE-L2-V1","bridgeMediatorAddress":"0x87c511c8aE3fAF0063b3F3CF9C6ab96c4AA5C60c","olasAddress":"0xFC2E6e6BCbd49ccf3A5f029c79984372DcBFE527","multisigProxyHash130":"0xb89c1b3bdf2cf8827818646bce9a8f6e372885f8c55e5c07acbd307cb133b000","serviceRegistryAddress":"0x3d77596beb0f130a4415df3D2D8232B3d3D31e44","operatorWhitelistAddress":"0x63e66d7ad413C01A7b49C7FF4e3Bb765C4E4bd1b","serviceRegistryTokenUtilityAddress":"0xBb7e1D6Cb6F243D6bdE81CE92a9f2aFF7Fbe7eac","serviceManagerTokenAddress":"0xFbBEc0C8b13B38a9aC0499694A69a10204c5E2aB","gnosisSafeMultisigImplementationAddress":"0xE43d4F4103b623B61E095E8bEA34e1bc8979e168","gnosisSafeSameAddressMultisigImplementationAddress":"0xb09CcF0Dbf0C178806Aaee28956c74bd66d21f73","stakingTokenAddress":"0x63C2c53c09dE534Dd3bc0b7771bf976070936bAC","stakingNativeTokenAddress":"","minStakingDepositLimit":"10000000000000000000000","timeForEmissionsLimit":"2592000","numServicesLimit":"100","apyLimit":"3000000000000000000","stakingVerifierAddress":"0x526E064cB694E8f5B7DB299158e17F33055B3943","stakingFactoryAddress":"0xa45E64d13A30a51b91ae0eb182e88a40e9b18eD8","L1CrossDomainMessengerProxyAddress":"0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1"} \ No newline at end of file +{"contractVerification":true,"useLedger":true,"derivationPath":"m/44'/60'/2'/0/0","providerName":"optimistic","networkURL":"https://mainnet.optimism.io","gasPriceInGwei":"2","gnosisSafeAddress":"0xd9Db270c1B5E3Bd161E8c8503c55cEABeE709552","gnosisSafeProxyFactoryAddress":"0xa6B71E26C5e0845f74c812102Ca7114b6a896AB2","baseURI":"https://gateway.autonolas.tech/ipfs/","serviceRegistryName":"Service Registry L2","serviceRegistrySymbol":"AUTONOLAS-SERVICE-L2-V1","bridgeMediatorAddress":"0x87c511c8aE3fAF0063b3F3CF9C6ab96c4AA5C60c","olasAddress":"0xFC2E6e6BCbd49ccf3A5f029c79984372DcBFE527","multisigProxyHash130":"0xb89c1b3bdf2cf8827818646bce9a8f6e372885f8c55e5c07acbd307cb133b000","serviceRegistryAddress":"0x3d77596beb0f130a4415df3D2D8232B3d3D31e44","operatorWhitelistAddress":"0x63e66d7ad413C01A7b49C7FF4e3Bb765C4E4bd1b","serviceRegistryTokenUtilityAddress":"0xBb7e1D6Cb6F243D6bdE81CE92a9f2aFF7Fbe7eac","serviceManagerTokenAddress":"0xFbBEc0C8b13B38a9aC0499694A69a10204c5E2aB","gnosisSafeMultisigImplementationAddress":"0x5953f21495BD9aF1D78e87bb42AcCAA55C1e896C","gnosisSafeSameAddressMultisigImplementationAddress":"0xb09CcF0Dbf0C178806Aaee28956c74bd66d21f73","stakingTokenAddress":"0x63C2c53c09dE534Dd3bc0b7771bf976070936bAC","stakingNativeTokenAddress":"","minStakingDepositLimit":"10000000000000000000000","timeForEmissionsLimit":"2592000","numServicesLimit":"100","apyLimit":"3000000000000000000","stakingVerifierAddress":"0x526E064cB694E8f5B7DB299158e17F33055B3943","stakingFactoryAddress":"0xa45E64d13A30a51b91ae0eb182e88a40e9b18eD8","L1CrossDomainMessengerProxyAddress":"0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1"} \ No newline at end of file diff --git a/scripts/proposals/proposal_12_staking_verifier_change_limits_set_implementation_optimistic.js b/scripts/proposals/proposal_12_staking_verifier_change_limits_set_implementation_optimistic.js index 20672f84..55b055ea 100644 --- a/scripts/proposals/proposal_12_staking_verifier_change_limits_set_implementation_optimistic.js +++ b/scripts/proposals/proposal_12_staking_verifier_change_limits_set_implementation_optimistic.js @@ -16,7 +16,7 @@ async function main() { console.log("Current block number mainnet: " + result); }); - const optimisticURL = "https://optimism.drpc.org"; + const optimisticURL = parsedData.networkURL; const optimisticProvider = new ethers.providers.JsonRpcProvider(optimisticURL); await optimisticProvider.getBlockNumber().then((result) => { console.log("Current block number optimistic: " + result); @@ -45,9 +45,17 @@ async function main() { const stakingVerifierABI = parsedFile["abi"]; const stakingVerifier = new ethers.Contract(stakingVerifierAddress, stakingVerifierABI, optimisticProvider); + // ServiceRegistryL2 address on optimism + const serviceRegistryAddress = parsedData.serviceRegistryAddress; + const serviceRegistryJSON = "artifacts/contracts/ServiceRegistryL2.sol/ServiceRegistryL2.json"; + contractFromJSON = fs.readFileSync(serviceRegistryJSON, "utf8"); + parsedFile = JSON.parse(contractFromJSON); + const serviceRegistryABI = parsedFile["abi"]; + const serviceRegistry = new ethers.Contract(serviceRegistryAddress, serviceRegistryABI, optimisticProvider); + // Timelock contract across the bridge must change staking limits const value = 0; - const target = stakingVerifierAddress; + let target = stakingVerifierAddress; let rawPayload = stakingVerifier.interface.encodeFunctionData("changeStakingLimits", [parsedData.minStakingDepositLimit, parsedData.timeForEmissionsLimit, parsedData.numServicesLimit, parsedData.apyLimit]); @@ -66,6 +74,28 @@ async function main() { [target, value, payload.length, payload] ).slice(2); + target = serviceRegistryAddress; + // Optimism + const oldMultisigImplementationAddress = "0xE43d4F4103b623B61E095E8bEA34e1bc8979e168"; + // Base + //const oldMultisigImplementationAddress = "0xBb7e1D6Cb6F243D6bdE81CE92a9f2aFF7Fbe7eac"; + rawPayload = serviceRegistry.interface.encodeFunctionData("changeMultisigPermission", + [oldMultisigImplementationAddress, false]); + payload = ethers.utils.arrayify(rawPayload); + data += ethers.utils.solidityPack( + ["address", "uint96", "uint32", "bytes"], + [target, value, payload.length, payload] + ).slice(2); + + const multisigImplementationAddress = parsedData.gnosisSafeMultisigImplementationAddress; + rawPayload = serviceRegistry.interface.encodeFunctionData("changeMultisigPermission", + [multisigImplementationAddress, true]); + payload = ethers.utils.arrayify(rawPayload); + data += ethers.utils.solidityPack( + ["address", "uint96", "uint32", "bytes"], + [target, value, payload.length, payload] + ).slice(2); + // Proposal preparation console.log("Proposal 12. Change staking limits on optimism in StakingVerifier and whitelist StakingTokenImplementation in StakingFactory\n"); // Build the bridge payload diff --git a/scripts/proposals/proposal_13_staking_verifier_change_limits_set_implementation_celo.js b/scripts/proposals/proposal_13_staking_verifier_change_limits_set_implementation_celo.js index 9f7119ac..9872cf77 100644 --- a/scripts/proposals/proposal_13_staking_verifier_change_limits_set_implementation_celo.js +++ b/scripts/proposals/proposal_13_staking_verifier_change_limits_set_implementation_celo.js @@ -35,12 +35,20 @@ async function main() { const stakingVerifierAddress = parsedData.stakingVerifierAddress; const stakingVerifierJSON = "artifacts/contracts/staking/StakingVerifier.sol/StakingVerifier.json"; contractFromJSON = fs.readFileSync(stakingVerifierJSON, "utf8"); - const parsedFile = JSON.parse(contractFromJSON); + let parsedFile = JSON.parse(contractFromJSON); const stakingVerifierABI = parsedFile["abi"]; const stakingVerifier = new ethers.Contract(stakingVerifierAddress, stakingVerifierABI, celoProvider); + // ServiceRegistryL2 address on optimism + const serviceRegistryAddress = parsedData.serviceRegistryAddress; + const serviceRegistryJSON = "artifacts/contracts/ServiceRegistryL2.sol/ServiceRegistryL2.json"; + contractFromJSON = fs.readFileSync(serviceRegistryJSON, "utf8"); + parsedFile = JSON.parse(contractFromJSON); + const serviceRegistryABI = parsedFile["abi"]; + const serviceRegistry = new ethers.Contract(serviceRegistryAddress, serviceRegistryABI, celoProvider); + // Timelock contract across the bridge must change staking limits - const target = stakingVerifierAddress; + let target = stakingVerifierAddress; const value = 0; let rawPayload = stakingVerifier.interface.encodeFunctionData("changeStakingLimits", [parsedData.minStakingDepositLimit, parsedData.timeForEmissionsLimit, parsedData.numServicesLimit, @@ -60,12 +68,31 @@ async function main() { [target, value, payload.length, payload] ).slice(2); + target = serviceRegistryAddress; + const oldMultisigImplementationAddress = "0x63e66d7ad413C01A7b49C7FF4e3Bb765C4E4bd1b"; + rawPayload = serviceRegistry.interface.encodeFunctionData("changeMultisigPermission", + [oldMultisigImplementationAddress, false]); + payload = ethers.utils.arrayify(rawPayload); + data += ethers.utils.solidityPack( + ["address", "uint96", "uint32", "bytes"], + [target, value, payload.length, payload] + ).slice(2); + + const multisigImplementationAddress = parsedData.gnosisSafeMultisigImplementationAddress; + rawPayload = serviceRegistry.interface.encodeFunctionData("changeMultisigPermission", + [multisigImplementationAddress, true]); + payload = ethers.utils.arrayify(rawPayload); + data += ethers.utils.solidityPack( + ["address", "uint96", "uint32", "bytes"], + [target, value, payload.length, payload] + ).slice(2); + const targetChain = 14; // celo const minGasLimit = "2000000"; // Get the transfer cost const transferCost = await wormholeRelayer["quoteEVMDeliveryPrice(uint16,uint256,uint256)"](targetChain, 0, minGasLimit); // Multiply x10 to avoid cost fluctuations - const transferCostFinal = transferCost.nativePriceQuote.mul(10); + const transferCostFinal = transferCost.nativePriceQuote; // Proposal preparation console.log("Proposal 13. Change staking limits on celo in StakingVerifier and whitelist StakingTokenImplementation in StakingFactory\n"); diff --git a/scripts/proposals/proposal_15_staking_verifier_change_limits_set_implementation_arbitrum.js b/scripts/proposals/proposal_15_staking_verifier_change_limits_set_implementation_arbitrum.js index 9f301535..331537b7 100644 --- a/scripts/proposals/proposal_15_staking_verifier_change_limits_set_implementation_arbitrum.js +++ b/scripts/proposals/proposal_15_staking_verifier_change_limits_set_implementation_arbitrum.js @@ -67,11 +67,11 @@ async function main() { }, maxSubmissionFee: { base: undefined, - percentIncrease: ethers.BigNumber.from(30), + percentIncrease: ethers.BigNumber.from(1000), }, maxFeePerGas: { base: undefined, - percentIncrease: ethers.BigNumber.from(30), + percentIncrease: ethers.BigNumber.from(1000), }, }; @@ -128,7 +128,7 @@ async function main() { L1ToL2MessageGasParams.gasLimit, gasPriceBid, calldata2]); const targets = [inboxAddress, inboxAddress]; - const values = [L1ToL2MessageGasParams.deposit, L1ToL2MessageGasParams2.deposit]; + const values = [L1ToL2MessageGasParams.deposit.mul(10), L1ToL2MessageGasParams2.deposit.mul(10)]; const callDatas = [timelockCalldata, timelockCalldata2]; const description = "Change staking limits on arbitrum in StakingVerifier and whitelist StakingTokenImplementation in StakingFactory";