ChainLocks#

Dash’s ChainLock feature leverages LLMQ Signing Requests/Sessions to reduce uncertainty when receiving funds and remove the possibility of 51% mining attacks.

For each block, an LLMQ of a few hundred masternodes (300-400) is selected and each participating member signs the first block that it sees extending the active chain at the current block height. If enough members (at least 240) see the same block as the first block, they will be able to create a clsig message and propagate it to all nodes in the network.

If a valid clsig message is received by a node, it must reject all blocks (and any descendants) at the same height that do not match the block specified in the clsig message. This makes the decision on the active chain quick, easy and unambiguous. It also makes reorganizations below this block impossible.

A node that missed a clsig message can recover the ChainLock from the ChainLock signature that miners include in the coinbase transaction (CbTx) of later blocks.

With LLMQ-based InstantSend, a ChainLock is only attempted once each transaction in the block (and in any recent blocks that are not yet ChainLocked) is either locked via InstantSend or was first seen by the masternode at least 10 minutes earlier. If a block contains unlocked transactions, masternodes attempt to establish retroactive InstantSend locks for them prior to a ChainLock. Provider transactions (e.g., ProRegTx and ProUpServTx) are never locked via InstantSend, so a block containing one may wait up to about 10 minutes for its ChainLock unless the provider transaction was first seen at least 10 minutes earlier.

ChainLocks have been active on the Dash network since block 1088640 in June of 2019. Please read DIP8 ChainLocks for additional details.