When cooperation breaks down, it is possible to finalize a state channel without requiring on-demand cooperation of all
n participants. This is the so-called 'sad' path to finalizing a channel, and it requires a supported (but not necessarily
isFinal) state(s) being submitted to the chain.
forceMove function allows anyone holding the appropriate off-chain state(s) to register a challenge state on chain. It is designed to ensure that a state channel can progress or be finalized in the event of inactivity on behalf of a participant (e.g. the current mover).
The required data for this method consist of between
n states, along with
n signatures that imply a support proof for the challenge state. Once these are submitted (in an optimized format), and once relevant checks have passed, an
outcome is registered against the
channelId, with a finalization time set at some delay after the transaction is processed. This delay allows the challenge to be cleared by a timely and well-formed respond or checkpoint transaction. We'll get to those shortly. If no such transaction is forthcoming, the challenge will time out, allowing the
outcome registered to be finalized. A finalized outcome can then be used to extract funds from the channel (more on that below, too).
The challenger needs to sign this data:
in order to form
challengerSig. This signals their intent to forceMove this channel with this particular state. This mechanism allows the forceMove to be authorized only by a channel participant.
We provide a handy utility function
signChallengeMessage to form this signature.