diff --git a/src/tasks/sep/060-U18-rev-share-betanet/.env b/src/tasks/sep/060-U18-rev-share-betanet/.env new file mode 100644 index 000000000..02789f94b --- /dev/null +++ b/src/tasks/sep/060-U18-rev-share-betanet/.env @@ -0,0 +1 @@ +TENDERLY_GAS=15000000 \ No newline at end of file diff --git a/src/tasks/sep/060-U18-rev-share-betanet/README.md b/src/tasks/sep/060-U18-rev-share-betanet/README.md new file mode 100644 index 000000000..9a5ab5902 --- /dev/null +++ b/src/tasks/sep/060-U18-rev-share-betanet/README.md @@ -0,0 +1,22 @@ +# 060-U18-rev-share-betanet + +Status: READY TO SIGN + +## Objective + +Updates RevShare Betanet (revshare-beta-0) to U18. + +## Simulation & Signing + +```bash +cd src/tasks/sep/060-U18-rev-share-betanet + +# Testing +just simulate-stack sep 060-U18-rev-share-betanet + +# Commands to execute +just --dotenv-path $(pwd)/.env simulate +USE_KEYSTORE=1 just --dotenv-path $(pwd)/.env sign +# or USE_KEYSTORE=1 just sign-stack sep 060-U18-rev-share-betanet +SIGNATURES=0x just execute +``` diff --git a/src/tasks/sep/060-U18-rev-share-betanet/VALIDATION.md b/src/tasks/sep/060-U18-rev-share-betanet/VALIDATION.md new file mode 100644 index 000000000..9f8ea428e --- /dev/null +++ b/src/tasks/sep/060-U18-rev-share-betanet/VALIDATION.md @@ -0,0 +1,19 @@ +## Expected Domain and Message Hashes + +First, we need to validate the domain and message hashes. These values should match both the values on your ledger and +the values printed to the terminal when you run the task. + +> [!CAUTION] +> +> Before signing, ensure the below hashes match what is on your ledger. +> +> ### Betanet 1/1 Safe (`0xe934Dc97E347C6aCef74364B50125bb8689c40ff`) +> +> - Domain Hash: `0x07e03428d7125835eca12b6dd1a02903029b456da3a091ecd66fda859fbce61e` +> - Message Hash: `0x1ee6ecb9c616384caf288af3520246f40161c8fa4623dccf51461de3db516ab0` + +## Task Calldata + +``` +0x82ad56cb000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000f0a2e224519e876979ea6b2cd15ef5cc3d6703bd0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a4cbeda5a7000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000010000000000000000000000009e964e030ef490ff88b0e4ff5846d80f286d5f2103a7021f5a914968290be4b0ae8c4094e52842fc356ce1e79d3bf8485c412e0703203b5839f05b5a88815521c09982655c9f41c1d451665ec7c79951fd4a955200000000000000000000000000000000000000000000000000000000 +``` diff --git a/src/tasks/sep/060-U18-rev-share-betanet/addresses.json b/src/tasks/sep/060-U18-rev-share-betanet/addresses.json new file mode 100644 index 000000000..a08b224d7 --- /dev/null +++ b/src/tasks/sep/060-U18-rev-share-betanet/addresses.json @@ -0,0 +1,18 @@ +{ + "420120033": { + "ProxyAdminOwner": "0xe934Dc97E347C6aCef74364B50125bb8689c40ff", + "SystemConfigProxy": "0x9E964E030Ef490fF88b0e4ff5846D80F286D5F21", + "L1CrossDomainMessengerProxy": "0x9ab3e890a6Cb011b0EcE3C3f137fd162f6c7F231", + "L1StandardBridgeProxy": "0x7173B9e76f8316De85cf5cb9CA3Cf998A2f24ed0", + "OptimismPortalProxy": "0x4fC40f2D8cf14925567938d209EB493a43347A79", + "DisputeGameFactoryProxy": "0xb9353415381A665eE9ACC313e586fB8667D554C8", + "DelayedWETHProxy": "0xFb19493EEFE1cDd3203204b389595Db86E94989b", + "PermissionedDelayedWETHProxy": "0xFb19493EEFE1cDd3203204b389595Db86E94989b", + "AnchorStateRegistryProxy": "0x36e3368A370480350b665afe6E53a427a7b2e8d4", + "AddressManager": "0x38538354Fc6979201B734FA28374be95C258BB1a", + "L1ERC721BridgeProxy": "0x4bbdaAC75C609858D6d14A7EbE9dfeAA62010691", + "Proposer": "0x40aed6d9ef3d694aeb406d210db82613b67cf99d", + "Challenger": "0xf6015e1850d6622921a647a76ffd892ba6870b75", + "OptimismMintableERC20FactoryProxy": "0x307e1D3019024ec7851982B10289696f9801E270" + } +} diff --git a/src/tasks/sep/060-U18-rev-share-betanet/config.toml b/src/tasks/sep/060-U18-rev-share-betanet/config.toml new file mode 100644 index 000000000..9773f2b33 --- /dev/null +++ b/src/tasks/sep/060-U18-rev-share-betanet/config.toml @@ -0,0 +1,27 @@ +# RevShare Betanet on U18 +l2chains = [ + {name = "revshare-beta-0", chainId = 420120033} +] + +# Addresses for this task can be found here: https://github.com/ethereum-optimism/devnets/tree/main/betanets/revshare-beta + +fallbackAddressesJsonPath = "src/tasks/sep/060-U18-rev-share-betanet/addresses.json" + +templateName = "OPCMUpgradeV600" + +[[opcmUpgrades]] +chainId = 420120033 +# U18 prestates for betanet: https://github.com/ethereum-optimism/devnets/blob/main/betanets/revshare-beta/op-program/prestates.json +cannonPrestate = "0x03a7021f5a914968290be4b0ae8c4094e52842fc356ce1e79d3bf8485c412e07" +cannonKonaPrestate = "0x03203b5839f05b5a88815521c09982655c9f41c1d451665ec7c79951fd4a9552" +expectedValidationErrors = "OVERRIDES-L1PAOMULTISIG,OVERRIDES-CHALLENGER,SYSCON-130" +# OVERRIDES-L1PAOMULTISIG,OVERRIDES-CHALLENGER: these are expected as they are not the standard OP Sepolia ones +# SYSCON-130: this is expected as the SystemConfig proxyAdmin on betanets is not the standard OP Sepolia one + +[addresses] +OPCM = "0xf0a2e224519e876979ea6b2cd15ef5cc3d6703bd" # v600 OPCM source: https://github.com/ethereum-optimism/superchain-registry/blob/c84ed822ae5a65500d8c0e323460fa688cfcca22/validation/standard/standard-versions-sepolia.toml#L23C56-L23C98 + +[stateOverrides] +0xe934Dc97E347C6aCef74364B50125bb8689c40ff = [ + {key = "0x0000000000000000000000000000000000000000000000000000000000000005", value = 66} +] diff --git a/src/tasks/sep/061-betanet-rev-share/.env b/src/tasks/sep/061-betanet-rev-share/.env new file mode 100644 index 000000000..737d60cbf --- /dev/null +++ b/src/tasks/sep/061-betanet-rev-share/.env @@ -0,0 +1 @@ +TENDERLY_GAS=16700000 \ No newline at end of file diff --git a/src/tasks/sep/061-betanet-rev-share/README.md b/src/tasks/sep/061-betanet-rev-share/README.md new file mode 100644 index 000000000..98cefe148 --- /dev/null +++ b/src/tasks/sep/061-betanet-rev-share/README.md @@ -0,0 +1,32 @@ +# 061 betanet-rev-share: RevShare Upgrade and Setup for Betanet + +Status: [READY TO SIGN] + +## Objective + +Upgrade proxies and setup RevShare contracts for the RevShare Betanet chain. This task: + +1. Deploys all needed contract implementations: + - FeeVaults + - FeeSplitter + - L1Withdrawer (pointing to the FeesDepositor on L1) + - RevShareCalculator (pointing to the L1Withdrawer and the ChainFeesRecipient) +2. Upgrades the fee vault proxy implementations (SequencerFeeVault, BaseFeeVault, L1FeeVault, OperatorFeeVault) on the Betanet L2 +3. Sets FeeSplitter predeploy to point to the new FeeSplitter implementation and initializes it with the RevShareCalculator address + +Target chain: + +- revshare-beta-0 (chainId: 420120033) + +## Simulation & Signing + +Simulation commands for each safe: + +```bash +# For stacked simulation (recommended for validation): +just simulate-stack sep 061-betanet-rev-share + +# For individual simulation: +cd src/tasks/sep/061-betanet-rev-share +SIMULATE_WITHOUT_LEDGER=1 just --dotenv-path "$(pwd)"/.env --justfile ../../../justfile simulate +``` diff --git a/src/tasks/sep/061-betanet-rev-share/VALIDATION.md b/src/tasks/sep/061-betanet-rev-share/VALIDATION.md new file mode 100644 index 000000000..1a94093a4 --- /dev/null +++ b/src/tasks/sep/061-betanet-rev-share/VALIDATION.md @@ -0,0 +1,19 @@ +## Expected Domain and Message Hashes + +First, we need to validate the domain and message hashes. These values should match both the values on your ledger and +the values printed to the terminal when you run the task. + +> [!CAUTION] +> +> Before signing, ensure the below hashes match what is on your ledger. +> +> ### Betanet 1/1 Safe (`0xe934Dc97E347C6aCef74364B50125bb8689c40ff`) +> +> - Domain Hash: `0x07e03428d7125835eca12b6dd1a02903029b456da3a091ecd66fda859fbce61e` +> - Message Hash: `0x00254ae422448797b14dba7eae2e4ae3b96763509d7010d2f403c28b0035f1ce` + +## Task Calldata + +``` +0x82ad56cb00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000071241bbae674967dd523e621c272ea32cf33119a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000e41a80dc3800000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000a1f4f424901e0773e68c714077bcdd5cf8bcec230000000000000000000000000000000000000000000000001bc16d674ec80000000000000000000000000000ed9b99a703bad32ac96fddc313c0652e379251fd00000000000000000000000000000000000000000000000000000000000c35000000000000000000000000007e31e1eafb4d1486c05743e5c496cb5042843d7a00000000000000000000000000000000000000000000000000000000 +``` diff --git a/src/tasks/sep/061-betanet-rev-share/addresses.json b/src/tasks/sep/061-betanet-rev-share/addresses.json new file mode 100644 index 000000000..f3546aa38 --- /dev/null +++ b/src/tasks/sep/061-betanet-rev-share/addresses.json @@ -0,0 +1,5 @@ +{ + "420120033": { + "ProxyAdminOwner": "0xe934Dc97E347C6aCef74364B50125bb8689c40ff" + } +} \ No newline at end of file diff --git a/src/tasks/sep/061-betanet-rev-share/config.toml b/src/tasks/sep/061-betanet-rev-share/config.toml new file mode 100644 index 000000000..e3934b059 --- /dev/null +++ b/src/tasks/sep/061-betanet-rev-share/config.toml @@ -0,0 +1,35 @@ +# RevShare Upgrade And Setup Configuration + +templateName = "RevShareUpgradeAndSetup" + +# L2 chains to target +l2chains = [{name = "revshare-beta-0", chainId = 420120033}] + +safeAddress = "ProxyAdminOwner" + +# RevShareContractsUpgrader https://sepolia.etherscan.io/address/0x71241bbae674967dd523e621c272ea32cf33119a +revShareUpgrader = "0x71241bbae674967dd523e621c272ea32cf33119a" + +# RevShare configurations (one per chain) +# Betanet Portal in Sepolia https://sepolia.etherscan.io/address/0xa1F4F424901e0773e68C714077bCDD5CF8BcEc23 +portals = ["0xa1F4F424901e0773e68C714077bCDD5CF8BcEc23"] + +# SequencerFeeVault.RECIPIENT() in the betanet. +chainFeesRecipients = ["0x7e31e1EafB4D1486C05743e5C496cB5042843d7a"] + +# 2 ether +l1WithdrawerMinWithdrawalAmounts = [2000000000000000000] + +# FeesDepositor https://sepolia.etherscan.io/address/0xed9B99a703BaD32AC96FDdc313c0652e379251Fd +l1WithdrawerRecipients = ["0xed9B99a703BaD32AC96FDdc313c0652e379251Fd"] +l1WithdrawerGasLimits = [800000] + +fallbackAddressesJsonPath = "src/tasks/sep/061-betanet-rev-share/addresses.json" + +[addresses] +ProxyAdminOwner = "0xe934Dc97E347C6aCef74364B50125bb8689c40ff" + +[stateOverrides] +0xe934Dc97E347C6aCef74364B50125bb8689c40ff = [ + {key = "0x0000000000000000000000000000000000000000000000000000000000000005", value = 67} +] \ No newline at end of file