Closed
Description
- Related issue on tendermint : Validator key rotation tendermint/tendermint#1136
- We moved this issue from tendermint to cosmos-sdk repository because the implementation causes almost no change in tendermint codebase, and most changes are on cosmos-sdk
1. Objectives
- to provide validators ability to rotate their validator consensus key
2. Use-case Overview
- how to rotate consensus key mapping to validator operator?
- create new random consensus key
- create and broadcast a transaction(RotateValCons) that the new consensus key is now coupled with the validator operator with signature from validator wallet key
- old consensus key becomes unable to participate on consensus after the update of key mapping state on-chain
- start validating with new consensus key
3. Considerations
- consensus key mapping information management strategy
- blockchain stores history of each key mapping changes.
- gaiad can search (from kvstore) corresponding consensus key paired with given validator operator for any arbitrary height in recent unbonding period
- gaiad does not need any historical mapping information which is past more than unbonding period
- limits
- a validator cannot rotate its consensus key more than N time for any unbonding period, to prevent spams
- a validator should contribute X atoms to community fund to rotate its consensus key, also to prevent spams
- parameters can be decided by governance and stored in genesis file
- slash module
- slash module can search corresponding consensus key for any height so that it can decide which consensus key is supposed to be used for given height
- pruning
- blockchain does not need to keep the historical key mapping after unbonding period past.
- when pruning is on, a node prunes all historical key mapping past unbonding period
- further implementation after this
- rotation of validator wallet key
- currently, validator wallet key and validator operator key is having identical root.
- implementing rotation of validator wallet key will create a lot of necessary structural changes in original codebase