feat(node): abort startup on wrong or missing x25519 registration#4709
feat(node): abort startup on wrong or missing x25519 registration#4709sveitser wants to merge 1 commit into
Conversation
From EPOCH_REWARD_VERSION onward a validator whose stake-table entry lacks connect info, or whose local x25519 key matches neither the contract head nor the three newest epoch stake tables (the window cliquenet dials), fails at startup instead of logging. Key rotation is tolerated in both directions; paths where verification is impossible (RPC failure, proxy < V3, head-fetch timeout) still warn and skip. ESPRESSO_NODE_SKIP_CLIQUENET_REGISTRATION_CHECK skips the check. Also fixes the dead version gate: the check compared base_version with equality, so it never ran on mainnet (base 0.4, upgrade 0.5).
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. |
| let head_fetch = async { | ||
| let events = membership | ||
| .fetcher() | ||
| .fetch_and_store_stake_table_events(addr, finalized.number) |
There was a problem hiding this comment.
Don't really like this since this fetch can take a very long time for a new node.
From EPOCH_REWARD_VERSION onward a validator whose stake-table entry lacks connect info, or whose local x25519 key matches neither the contract head nor the three newest epoch stake tables (the window cliquenet dials), fails at startup instead of logging. Key rotation is tolerated in both directions; paths where verification is impossible (RPC failure, proxy < V3, head-fetch timeout) still warn and skip. ESPRESSO_NODE_SKIP_CLIQUENET_REGISTRATION_CHECK skips the check.
Also fixes the dead version gate: the check compared base_version with equality, so it never ran on mainnet (base 0.4, upgrade 0.5).