diff --git a/pages/operators/chain-operators/tools.mdx b/pages/operators/chain-operators/tools.mdx index 3238c2873..8940801a2 100644 --- a/pages/operators/chain-operators/tools.mdx +++ b/pages/operators/chain-operators/tools.mdx @@ -16,6 +16,7 @@ This section provides information on chain monitoring options, deploying a block + diff --git a/pages/operators/chain-operators/tools/_meta.json b/pages/operators/chain-operators/tools/_meta.json index 40fdb8480..cdcd24668 100644 --- a/pages/operators/chain-operators/tools/_meta.json +++ b/pages/operators/chain-operators/tools/_meta.json @@ -4,6 +4,7 @@ "op-challenger": "op-challenger", "op-conductor": "op-conductor", "op-deployer": "op-deployer", + "op-validator": "op-validator", "op-txproxy": "op-txproxy", "proxyd": "proxyd", "fee-calculator": "Fee calculator" diff --git a/pages/operators/chain-operators/tools/op-validator.mdx b/pages/operators/chain-operators/tools/op-validator.mdx new file mode 100644 index 000000000..8b22960f2 --- /dev/null +++ b/pages/operators/chain-operators/tools/op-validator.mdx @@ -0,0 +1,115 @@ +--- +title: op-validator +description: Learn how to use op-validator to validate chain configurations and deployments. +lang: en-US +content_type: tutorial +topic: op-validator +personas: + - chain-operator + - protocol-developer +categories: + - tools + - op-validator +is_imported_content: 'false' +--- + +import {Callout, Steps} from 'nextra/components' + +# op-validator + + + Currently, `op-validator` is only available on Sepolia networks. + + +The `op-validator` is a tool for validating Standard OP Stack chain configurations and deployments to ensure they're in compliance with the [Standard Rollup Charter](/superchain/blockspace-charter#the-standard-rollup-charter). It works by calling into the `StandardValidator` smart contracts (`StandardValidatorV180` and `StandardValidatorV200`). These then perform a set of checks, and return error codes for any issues found. + +These checks include: + +* Contract implementations and versions +* Proxy configurations +* System parameters +* Cross-component relationships +* Security settings + +## How to use op-validator + + + ### Clone the monorepo + + ```bash + git clone https://github.com/ethereum-optimism/optimism.git + ``` + + ### Build the `op-validator` binary + + ```bash + cd optimism/op-validator + just build + ``` + + ### Run the `op-validator` binary + + ```bash + ./bin/op-validator validate v1.8.0 \ + --l1-rpc-url "https://ethereum-sepolia-rpc.publicnode.com" \ + --absolute-prestate "0x03f89406817db1ed7fd8b31e13300444652cdb0b9c509a674de43483b2f83568" \ + --proxy-admin "0x189aBAAaa82DfC015A588A7dbaD6F13b1D3485Bc" \ + --system-config "0x034edD2A225f7f429A63E0f1D2084B9E0A93b538" \ + --l2-chain-id "11155420" \ + --fail + ``` + + ### Understanding the output + + In the previous command, we provided a non-standard absolute prestate. The `op-validator` returned the following output to describe the discrepancies between the provided absolute prestate and the expected prestate in the L1 smart contracts: + + ``` + | ERROR | DESCRIPTION | + |-----------------|--------------------------------| + | PDDG-40 | Permissioned dispute game | + | | absolute prestate mismatch | + | PDDG-ANCHORP-40 | Permissioned dispute game | + | | anchor state registry root | + | | hash mismatch | + | PLDG-40 | Permissionless dispute game | + | | absolute prestate mismatch | + | PLDG-ANCHORP-40 | Permissionless dispute game | + | | anchor state registry root | + | | hash mismatch | + + Validation errors found + ``` + + +## Usage + +The validator supports different protocol versions through subcommands: + +```bash +op-validator validate [version] [flags] +``` + +Choose a version based on your `op-contracts` version: + +* `v1.8.0` - For validating `op-contracts/1.8.0` +* `v2.0.0` - For validating `op-contracts/2.0.0` + +### Flags + +| Option | Description | Required/Optional | +| --------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------- | +| `--l1-rpc-url` | L1 RPC URL (can also be set via `L1_RPC_URL` environment variable) | Required | +| `--absolute-prestate` | Absolute prestate as hex string | Required | +| `--proxy-admin` | Proxy admin address as hex string. This should be a specific chain's proxy admin contract on L1. It is not the proxy admin owner or the superchain proxy admin. | Required | +| `--system-config` | System config proxy address as hex string | Required | +| `--l2-chain-id` | L2 chain ID | Required | +| `--fail` | Exit with non-zero code if validation errors are found (defaults to true) | Optional | + +### Example + +```bash +op-validator validate v2.0.0 \ + --l1-rpc-url "L1_RPC_URL" \ + --absolute-prestate "0x1234..." \ + --proxy-admin "0xabcd..." \ +``` diff --git a/pages/superchain/standard-configuration.mdx b/pages/superchain/standard-configuration.mdx index cef55b056..b6fdcc6c7 100644 --- a/pages/superchain/standard-configuration.mdx +++ b/pages/superchain/standard-configuration.mdx @@ -110,12 +110,15 @@ The [Superchain Registry](/superchain/superchain-registry) is the authoritative Familiarize yourself with the [OP Stack specifications](https://specs.optimism.io/protocol/configurability.html) and the Blockspace Charter. 2. **Use op-deployer:** - Leverage op-deployer to ensure your chain aligns with standard configurations. + Leverage [op-deployer](/operators/chain-operators/tools/op-deployer) to ensure your chain aligns with standard configurations. -3. **Seek guidance:** +3. **Verify deployment with op-validator:** + Use [op-validator](/operators/chain-operators/tools/op-validator) to verify your chain's deployment. + +4. **Seek guidance:** Consult the [developer support](https://github.com/ethereum-optimism/developers/discussions) team for clarifications on standardization. -4. **Contribute to the ecosystem:** +5. **Contribute to the ecosystem:** Engage with the [Optimism Collective](https://community.optimism.io/) to share feedback and propose improvements. ## References diff --git a/words.txt b/words.txt index 326d37a04..25d6705da 100644 --- a/words.txt +++ b/words.txt @@ -115,6 +115,7 @@ ETHERBASE etherbase Ethernity Ethernow +ethpandaops ETHSTATS ethstats EVMTIMEOUT