Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/addresses.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
SuperchainConfig = "0x95703e0982140D16f8ebA6d158FccEde42f04a4C"
ProtocolVersions = "0x8062AbC286f5e7D9428a0Ccb9AbD71e50d93b935" # Cannot be found by chain discovery in SuperchainAddressRegistry.sol
DeputyGuardianModule = "0xc6901F65369FC59fC1B4D6D6bE7A2318Ff38dB5B"
DeputyPauseModule = "0x76fC2F971FB355D0453cF9F64d3F9E4f640E1754"
FoundationUpgradeSafe = "0x847B5c174615B1B7fDF770882256e2D3E95b9D92"
SecurityCouncil = "0xc2819DC788505Aac350142A7A707BF9D03E3Bd03"
LivenessGuard = "0x24424336F04440b1c28685a38303aC33C9D14a25" # LivenessGuard on security council
Expand Down
26 changes: 26 additions & 0 deletions src/tasks/eth/052-deputy-pause-key-rotation/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# 052-deputy-pause-key-rotation

Status: READY TO SIGN

## Objective

Rotates the `DeputyPauseModule` Deputy EOA from `0x352f1defb49718e7ea411687e850aa8d6299f7ac` to `0x2fA150379bF32b6d79Eeb4ff9bD280E76049a87c`.
To achieve this, we will use the `setDeputy` function of the `DeputyPauseModule` contract deployed at `0x76fC2F971FB355D0453cF9F64d3F9E4f640E1754`.

## Simulation

Please see the "Simulating and Verifying the Transaction" instructions in [SINGLE.md](../../../SINGLE.md).
When simulating, ensure the logs say `Using script /your/path/to/superchain-ops/src/template/DeputyPauseKeyRotationTemplate.sol`.
This ensures all safety checks are run. If the default `SignFromJson.s.sol` script is shown (without the full path), something is wrong and the safety checks will not run.

## State Validation

Please see the instructions for [validation](./VALIDATION.md).

## Execution

Rotates the `DeputyPauseModule` Deputy EOA from `0x352f1defb49718e7ea411687e850aa8d6299f7ac` to `0x2fA150379bF32b6d79Eeb4ff9bD280E76049a87c` in the [DeputyPauseModule](https://etherscan.io/address/0x76fC2F971FB355D0453cF9F64d3F9E4f640E1754#code).

## Signing and execution

This task has to be signed by the [FoundationUpgradeSafe](https://etherscan.io/address/0x847B5c174615B1B7fDF770882256e2D3E95b9D92).
60 changes: 60 additions & 0 deletions src/tasks/eth/052-deputy-pause-key-rotation/VALIDATION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# Validation

This document can be used to validate the state diff resulting from the execution of the upgrade
transaction.

For each contract listed in the state diff, please verify that no contracts or state changes shown in the Tenderly diff are missing from this document. Additionally, please verify that for each contract:

- The following state changes (and none others) are made to that contract. This validates that no unexpected state changes occur.
- All addresses (in section headers and storage values) match the provided name, using the Etherscan and Superchain Registry links provided. This validates the bytecode deployed at the addresses contains the correct logic.
- All key values match the semantic meaning provided, which can be validated using the storage layout links provided.

## Expected Domain and Message Hashes

> [!CAUTION]
> Before signing, ensure the below hashes match what is on your ledger.
>
> ### Optimism Foundation
>
> Domain Hash: 0xa4a9c312badf3fcaa05eafe5dc9bee8bd9316c78ee8b0bebe3115bb21b732672
> Message Hash: 0x172732ded2946632e172146b24eb6c790a9d5572adaca9b430380800c23306cc

## State Overrides

The following state overrides should be seen:

### `0x847B5c174615B1B7fDF770882256e2D3E95b9D92` (The Optimism Foundation Upgrade Safe)

Links:

- [Etherscan](https://etherscan.io/address/0x847B5c174615B1B7fDF770882256e2D3E95b9D92)

Enables the simulation by setting the threshold to 1:

- **Key:** `0x0000000000000000000000000000000000000000000000000000000000000004` <br/>
**Value:** `0x0000000000000000000000000000000000000000000000000000000000000001`

## State Changes

### `0x847b5c174615b1b7fdf770882256e2d3e95b9d92` (Foundation Upgrade Safe)

- **Key:** `0x0000000000000000000000000000000000000000000000000000000000000005`
- **Decoded Kind:** `uint256`
- **Before:** `118`
- **After:** `119`
- **Summary:** nonce
- **Detail:**

This updates the nonce of the Foundation Upgrade Safe.

---

### `0x76fc2f971fb355d0453cf9f64d3f9e4f640e1754` (DeputyPauseModule)

- **Key:** `0x0000000000000000000000000000000000000000000000000000000000000002`
- **Before:** `0x000000000000000000000000352f1defb49718e7ea411687e850aa8d6299f7ac`
- **After:** `0x0000000000000000000000002fa150379bf32b6d79eeb4ff9bd280e76049a87c`
- **Summary:**
- **Detail:**

This updates the previous deputy `0x352f1defB49718e7Ea411687E850aA8d6299F7aC` to `0x2fA150379bF32b6d79Eeb4ff9bD280E76049a87c`.
13 changes: 13 additions & 0 deletions src/tasks/eth/052-deputy-pause-key-rotation/config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
l2chains = [{name = "OP Mainnet", chainId = 10}]
templateName = "DeputyPauseKeyRotationTemplate"
safeAddressString = "FoundationUpgradeSafe" # Override: template defaults to FoundationOperationsSafe (Sepolia); Mainnet rotation is executed by FuS.

newDeputy = "0x2fA150379bF32b6d79Eeb4ff9bD280E76049a87c"

newDeputySignature = "0xbfa0011dc0b49416bc4f84fe477d0c059b2871f46e2e186e1fd5172c1cf67940384f8b0944dcf5c88673b5c80c51a38f55c39500afa24896eafc285f8a891a221c"

[stateOverrides]
# Nonce override for simulation (storage slot 0x5 is the nonce)
0x847B5c174615B1B7fDF770882256e2D3E95b9D92 = [
{key = "0x0000000000000000000000000000000000000000000000000000000000000005", value = 118}
]
4 changes: 3 additions & 1 deletion test/tasks/example/sep/007-deputy-pause-key-rotation/.env
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
FORK_BLOCK_NUMBER=10698643
FORK_BLOCK_NUMBER=10711555



Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ newDeputy = "0x8D2AAe4009418Ef6D83F1F2c90D4dAc3cE2b5D4f"

newDeputySignature = "0x9c993717c629503892a2779150447a39cd8d1a28d6439a2d4fa7c49a32f4be941cbf0730ffdb5366dcebf3c7fdb1757e08724caab6404e8519df8abf728ba4ca1c"

safeAddressString = "FoundationUpgradeSafe"