Skip to content

op-interop-filter: Service skeleton with flags and metrics#8

Merged
karlfloersch merged 3 commits intointerop-filter-basefrom
feat/interop-filter-skeleton
Nov 27, 2025
Merged

op-interop-filter: Service skeleton with flags and metrics#8
karlfloersch merged 3 commits intointerop-filter-basefrom
feat/interop-filter-skeleton

Conversation

@opsuperchain
Copy link
Copy Markdown
Collaborator

@opsuperchain opsuperchain commented Nov 26, 2025

Description

Adds the op-interop-filter service skeleton:

  1. CLI flags with StringSliceFlag for --l2-rpcs (chain ID queried from RPC)
  2. Service lifecycle (start/stop) following op-service patterns
  3. RPC server with supervisor namespace for checkAccessList
  4. Metrics with doc subcommand for documentation
  5. Stub backend (actual logic in follow-up PR)

This service validates interop executing messages for op-geth/op-reth transaction filtering. Any reorg triggers failsafe which disables all interop transactions.

Tests

Unit tests will be added in the follow-up logic PR. This skeleton PR focuses on service structure.

Metadata

  • Part 1 of 4 in the op-interop-filter stack

@opsuperchain opsuperchain force-pushed the feat/interop-filter-skeleton branch 4 times, most recently from aafc0e1 to 473d52e Compare November 27, 2025 05:26
@opsuperchain opsuperchain changed the base branch from develop to interop-filter-base November 27, 2025 05:27
Add op-interop-filter service scaffolding:

**Core structure:**
- flags/flags.go: CLI flag definitions with L2 RPC parsing
- flags/flags_test.go: Unit tests for flag parsing
- filter/config.go: Configuration struct and parsing
- filter/service.go: Service lifecycle management
- filter/frontend.go: RPC handlers (supervisor and admin)
- filter/backend.go: Stub backend (returns ErrUninitialized)
- metrics/metrics.go: Prometheus metrics interface and implementation
- cmd/main.go: Application entry point

**Build infrastructure:**
- justfile and Makefile for building
- docker-bake.hcl target
- Dockerfile builder and target stages
- Dockerfile.dockerignore allowlist entry

The service compiles and starts but CheckAccessList returns
ErrUninitialized until the actual implementation is added.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@opsuperchain opsuperchain force-pushed the feat/interop-filter-skeleton branch from 473d52e to 381bb87 Compare November 27, 2025 05:31
opsuperchain and others added 2 commits November 27, 2025 05:58
…patterns

- Change --l2-rpcs to StringSliceFlag (query chain ID from RPC)
- Remove custom ParseL2RPCs parsing and tests
- Add doc subcommand for metrics documentation
- Add Document() method to metrics
- Fix NewMetrics() to take procName parameter
- Remove Required: true from flag (use CheckRequired only)
- Use "message" key in log.Crit for consistency

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@opsuperchain opsuperchain changed the title feat(op-interop-filter): add skeleton and flags [1/4] op-interop-filter: Service skeleton with flags and metrics Nov 27, 2025
@karlfloersch karlfloersch merged commit 5138bbd into interop-filter-base Nov 27, 2025
opsuperchain pushed a commit that referenced this pull request Mar 8, 2026
…imism#19281)

* fix(contracts): address audit findings #14, #6, #8, #13, #19

- #14: Reuse existing DelayedWETH from SystemConfig instead of deploying
  a new one in the Migrator, preventing divergence with future upgrades
- #6: Document that hardcoded game type lists in OPCMv2 and Migrator are
  intentional and must be kept in sync when new types are added
- #8: Document that migrate() does not enforce SuperchainConfig version floor
- #13: Document why migration game config validation is deliberately minimal
- #19: Document theoretical risk in AnchorStateRegistry.isGameRegistered
  when ASR proxy is replaced non-atomically

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix(contracts): add cross-reference comment to GameTypes library

Add a notice to the GameTypes library reminding developers to update
the hardcoded game type lists in OPContractsManagerMigrator and
OPContractsManagerV2's _assertValidFullConfig when adding new types.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix(contracts): bump OPContractsManagerV2 version for rebase

Bump OPContractsManagerV2 from 7.0.9 to 7.0.10 to account for the
comment-only source change (cross-reference note added in prior commit)
that affects the bytecode metadata hash.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix(contracts): bump OPContractsManagerV2 version to 7.0.11 for semver-diff CI fix

* fix(contracts): apply forge fmt and bump versions for formatting changes

forge fmt changed OPContractsManager, FaultDisputeGame, SuperFaultDisputeGame,
and several other files. Bump patch versions for the contracts with hash changes,
and regenerate semver-lock and snapshots.

- OPContractsManager: 6.0.3 -> 6.0.4
- FaultDisputeGame: 2.4.0 -> 2.4.1
- SuperFaultDisputeGame: 0.7.0 -> 0.7.1

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: smartcontracts <smartcontracts@users.noreply.github.com>
karlfloersch pushed a commit that referenced this pull request Mar 17, 2026
* docs(staking): document pause bypass behavior in setAllowedStaker

* fix(staking): only reset lastUpdate on full unstake in _decreasePeData

Cantina audit finding #7: _decreasePeData unconditionally reset
lastUpdate on every decrease, penalizing partial unstakers by
resetting their staking weight. Now lastUpdate is only reset when
effectiveStake reaches zero.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* feat(staking): implement two-step ownership transfer

Cantina audit finding #8: transferOwnership now nominates a pending
owner who must call acceptOwnership() to finalize the transfer,
preventing irrevocable ownership loss from incorrect addresses.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* docs(staking): document lastUpdate reset trust assumption in setAllowedStaker

Cantina audit finding #10: when a beneficiary removes a staker from
their allowlist, the staker's lastUpdate is reset via _increasePeData,
losing accumulated staking weight. Document this as an inherent trust
assumption of the delegation model.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* chore: undo version change

* chore: upgrade natspec

* chore: update event emission order

* fix: wrong event args

* chore: add interface comments

* fix: pre-pr

* refactor: make ownable private functions public

* fix: pre-pr

* feat(ownable): reset pending owner on zeroaddress ownership transfer

* refactor: inherit OZ's ownable and use helper contract for mapping storage slot

* fix: ci

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants