Skip to content

fix: verify consensus rpc chain_id during startup#791

Open
0xpinara wants to merge 1 commit intoa16z:masterfrom
0xpinara:fix/verify-chain-id
Open

fix: verify consensus rpc chain_id during startup#791
0xpinara wants to merge 1 commit intoa16z:masterfrom
0xpinara:fix/verify-chain-id

Conversation

@0xpinara
Copy link
Copy Markdown

Summary

Calls the existing but unused Inner::check_rpc() method after sync completes. If the consensus RPC serves a different chain than configured, the client stops with IncorrectRpcNetwork instead of silently returning the wrong chain_id.

Changes

  • ethereum/src/consensus.rs — call check_rpc() after sync, before marking client as synced

Closes #544

Call the existing check_rpc() method after sync completes to
verify the consensus RPC's chain_id matches the configured
network. If there's a mismatch, the client stops with an
IncorrectRpcNetwork error instead of silently serving data
from the wrong chain.

Closes a16z#544
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.

Verify eth_chainId response

1 participant