Interchain Security Parameters
The parameters necessary for Interchain Security (ICS) are defined in
- the
Params
structure inproto/interchain_security/ccv/provider/v1/provider.proto
for the provider; - the
Params
structure inproto/interchain_security/ccv/consumer/v1/consumer.proto
for the consumer.
Time-based parameters
ICS relies on the following time-based parameters.
ProviderUnbondingPeriod
ProviderUnbondingPeriod
is the unbonding period on the provider chain as configured during chain genesis. This parameter can later be changed via governance.
ConsumerUnbondingPeriod
ConsumerUnbondingPeriod
is the unbonding period on the consumer chain.
ConsumerUnbondingPeriod
is set via the ConsumerAdditionProposal
governance proposal to add a new consumer chain.
It is recommended that every consumer chain set and unbonding period shorter than ProviderUnbondingPeriod
Example:
ConsumerUnbondingPeriod = ProviderUnbondingPeriod - one day
Unbonding operations (such as undelegations) are completed on the provider only after the unbonding period elapses on every consumer.
TrustingPeriodFraction
TrustingPeriodFraction
is used to calculate the TrustingPeriod
of created IBC clients on both provider and consumer chains.
Setting TrustingPeriodFraction
to 0.5
would result in the following:
TrustingPeriodFraction = 0.5
ProviderClientOnConsumerTrustingPeriod = ProviderUnbondingPeriod * 0.5
ConsumerClientOnProviderTrustingPeriod = ConsumerUnbondingPeriod * 0.5
Note that a light clients must be updated within the TrustingPeriod
in order to avoid being frozen.
For more details, see the IBC specification of Tendermint clients.
CCVTimeoutPeriod
CCVTimeoutPeriod
is the period used to compute the timeout timestamp when sending IBC packets.
For more details, see the IBC specification of Channel & Packet Semantics.
If a sent packet is not relayed within this period, then the packet times out. The CCV channel used by the interchain security protocol is closed, and the corresponding consumer is removed.
CCVTimeoutPeriod may have different values on the provider and consumer chains.
CCVTimeoutPeriod
on the provider must be larger thanConsumerUnbondingPeriod
CCVTimeoutPeriod
on the consumer is initial set via theConsumerAdditionProposal
InitTimeoutPeriod
InitTimeoutPeriod
is the maximum allowed duration for CCV channel initialization to execute.
For any consumer chain, if the CCV channel is not established within InitTimeoutPeriod
then the consumer chain will be removed and therefore will not be secured by the provider chain.
The countdown starts when the spawn_time
specified in the ConsumerAdditionProposal
is reached.
VscTimeoutPeriod
VscTimeoutPeriod
is the provider-side param that enables the provider to timeout VSC packets even when a consumer chain is not live.
If the VscTimeoutPeriod
is ever reached for a consumer chain that chain will be considered not live and removed from interchain security.
VscTimeoutPeriod
MUST be larger than the ConsumerUnbondingPeriod
.
BlocksPerDistributionTransmission
BlocksPerDistributionTransmission
is the number of blocks between rewards transfers from the consumer to the provider.
TransferPeriodTimeout
TransferPeriodTimeout
is the period used to compute the timeout timestamp when sending IBC transfer packets from a consumer to the provider.
If this timeout expires, then the transfer is attempted again after BlocksPerDistributionTransmission
blocks.
TransferPeriodTimeout
on the consumer is initial set via theConsumerAdditionProposal
gov proposal to add the consumerTransferPeriodTimeout
should be smaller thanBlocksPerDistributionTransmission x avg_block_time
Slash Throttle Parameters
SlashMeterReplenishPeriod
SlashMeterReplenishPeriod
exists on the provider such that once the slash meter becomes not-full, the slash meter is replenished after this period has elapsed.
The meter is replenished to an amount equal to the slash meter allowance for that block, or SlashMeterReplenishFraction * CurrentTotalVotingPower
.
SlashMeterReplenishFraction
SlashMeterReplenishFraction
exists on the provider as the portion (in range [0, 1]) of total voting power that is replenished to the slash meter when a replenishment occurs.
This param also serves as a maximum fraction of total voting power that the slash meter can hold. The param is set/persisted as a string, and converted to a sdk.Dec
when used.
MaxThrottledPackets
MaxThrottledPackets
exists on the provider as the maximum amount of throttled slash or vsc matured packets that can be queued from a single consumer before the provider chain halts, it should be set to a large value.
This param would allow provider binaries to panic deterministically in the event that packet throttling results in a large amount of state-bloat. In such a scenario, packet throttling could prevent a violation of safety caused by a malicious consumer, at the cost of provider liveness.
MaxThrottledPackets
was deprecated in ICS versions >= v3.2.0 due to the implementation of ADR-008.
RetryDelayPeriod
RetryDelayPeriod
exists on the consumer for ICS versions >= v3.2.0 (introduced by the implementation of ADR-008) and is the period at which the consumer retries to send a SlashPacket
that was rejected by the provider.