diff --git a/proto/interchain_security/ccv/provider/v1/genesis.proto b/proto/interchain_security/ccv/provider/v1/genesis.proto index dedfc72120..d52c249e90 100644 --- a/proto/interchain_security/ccv/provider/v1/genesis.proto +++ b/proto/interchain_security/ccv/provider/v1/genesis.proto @@ -10,32 +10,30 @@ import "interchain_security/ccv/provider/v1/provider.proto"; import "interchain_security/ccv/consumer/v1/consumer.proto"; import "interchain_security/ccv/consumer/v1/genesis.proto"; - // GenesisState defines the CCV provider chain genesis state message GenesisState { // empty for a new chain - uint64 valset_update_id = 1; + uint64 valset_update_id = 1; // empty for a new chain - repeated ConsumerState consumer_states = 2 [ + repeated ConsumerState consumer_states = 2 [ (gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"consumer_states\"" ]; // empty for a new chain repeated interchain_security.ccv.v1.UnbondingOp unbonding_ops = 3 - [ (gogoproto.nullable) = false ]; + [ (gogoproto.nullable) = false ]; // empty for a new chain interchain_security.ccv.v1.MaturedUnbondingOps mature_unbonding_ops = 4; - // empty for a new chain + // empty for a new chain repeated ValsetUpdateIdToHeight valset_update_id_to_height = 5 - [ (gogoproto.nullable) = false ]; + [ (gogoproto.nullable) = false ]; // empty for a new chain repeated ConsumerAdditionProposal consumer_addition_proposals = 6 - [ (gogoproto.nullable) = false ]; + [ (gogoproto.nullable) = false ]; // empty for a new chain repeated ConsumerRemovalProposal consumer_removal_proposals = 7 - [ (gogoproto.nullable) = false ]; - Params params = 8 - [ (gogoproto.nullable) = false ]; + [ (gogoproto.nullable) = false ]; + Params params = 8 [ (gogoproto.nullable) = false ]; } // consumer chain @@ -48,31 +46,33 @@ message ConsumerState { string client_id = 3; // InitalHeight defines the initial block height for the consumer chain uint64 initial_height = 4; - // LockUnbondingOnTimeout defines whether the unbonding funds should be released for this - // chain in case of a IBC channel timeout + // LockUnbondingOnTimeout defines whether the unbonding funds should be + // released for this chain in case of a IBC channel timeout bool lock_unbonding_on_timeout = 5; // ConsumerGenesis defines the initial consumer chain genesis states interchain_security.ccv.consumer.v1.GenesisState consumer_genesis = 6 - [ (gogoproto.nullable) = false ]; - // PendingValsetChanges defines the pending validator set changes for the consumer chain - repeated interchain_security.ccv.v1.ValidatorSetChangePacketData pending_valset_changes = 7 - [ (gogoproto.nullable) = false ]; + [ (gogoproto.nullable) = false ]; + // PendingValsetChanges defines the pending validator set changes for the + // consumer chain + repeated interchain_security.ccv.v1.ValidatorSetChangePacketData + pending_valset_changes = 7 [ (gogoproto.nullable) = false ]; repeated string slash_downtime_ack = 8; // UnbondingOpsIndex defines the unbonding operations on the consumer chain repeated UnbondingOpIndex unbonding_ops_index = 9 - [ (gogoproto.nullable) = false ]; + [ (gogoproto.nullable) = false ]; + KeyMap key_map = 10; } -// UnbondingOpIndex defines the genesis information for each unbonding operations index -// referenced by chain id and valset udpate id +// UnbondingOpIndex defines the genesis information for each unbonding +// operations index referenced by chain id and valset udpate id message UnbondingOpIndex { uint64 valset_update_id = 1; repeated uint64 unbonding_op_index = 2; } -// ValsetUpdateIdToHeight defines the genesis information for the mapping +// ValsetUpdateIdToHeight defines the genesis information for the mapping // of each valset udpate id to a block height message ValsetUpdateIdToHeight { - uint64 valset_update_id = 1; - uint64 height = 2; + uint64 valset_update_id = 1; + uint64 height = 2; } diff --git a/proto/interchain_security/ccv/provider/v1/keymap.proto b/proto/interchain_security/ccv/provider/v1/keymap.proto new file mode 100644 index 0000000000..4c66f8560a --- /dev/null +++ b/proto/interchain_security/ccv/provider/v1/keymap.proto @@ -0,0 +1,39 @@ +syntax = "proto3"; + +package interchain_security.ccv.provider.v1; + +option go_package = "github.com/cosmos/interchain-security/x/ccv/types"; + +import "gogoproto/gogo.proto"; +import "tendermint/crypto/keys.proto"; + +message LastUpdateMemo { + tendermint.crypto.PublicKey ck = 1; + tendermint.crypto.PublicKey pk = 2; + bytes cca = 3; + uint64 vscid = 4; + int64 power = 5; +} + +message KeyToKey { + tendermint.crypto.PublicKey from = 1; + tendermint.crypto.PublicKey to = 2; +} + +message KeyToLastUpdateMemo { + tendermint.crypto.PublicKey key = 1; + LastUpdateMemo last_update_memo = 2; +} + +message ConsAddrToKey { + bytes cons_addr = 1; + tendermint.crypto.PublicKey key = 2; +} + +message KeyMap { + repeated KeyToKey pk_to_ck = 1 [ (gogoproto.nullable) = false ]; + repeated KeyToKey ck_to_pk = 2 [ (gogoproto.nullable) = false ]; + repeated KeyToLastUpdateMemo ck_to_last_update_memo = 3 + [ (gogoproto.nullable) = false ]; + repeated ConsAddrToKey cca_to_ck = 4 [ (gogoproto.nullable) = false ]; +} \ No newline at end of file