State Channels — What you need to know

gravatar
By admin
 · 
November 16, 2022
 · 
3 min read

State Channels is the next step in blockchain-space technological development.

State Channels allow for entities to communicate with one another and to collectively compute functions that are represented by smart contracts. Much as is the case with any sort of a regular, run-of-the-mill legal contract, an arbiter is needed to prevent any potential malicious behaviour. In this case — we turn to the blockchain itself.

State Channels function and interact with:

  • the node: client connected to the blockchain that can be addressed via an IP address and port
  • the peer: participant in a channel
  • the channel: an off-chain method for two peers to exchange state updates,

Each node can have multiple channels, and a pair of nodes can also have multiple channels between each other, which should be multiplexed over one connection.

An ideal state channel design should be a strict improvement over handling interactions on the chain. In this case, benchmarking metrics are:

  • Privacy
  • Security
  • Speed
  • Cost

While on-chain interactions offer little-to-no privacy — on account of a lack of desire to hide the identity of interacting parties as well as their interactions — State Channels simply reveal that two parties engage in the establishment of a channel as well as the number of coins committed to that channel. Should both parties act in good faith, the specific nature of their interaction stays unrevealed because a mutual closing of a state channel requires no publishing of any state.

So, State Channels are a significant improvement in terms of privacy.

Moreover, State Channels offer a near-identical state of security as regular on-chain transactions do, in terms of:

  • Liveness: both peers can independently initiate the closing of a channel, and that operation is then processed by the blockchain with the usual assumptions of liveness.
  • Trust-less: since operations need to be signed by both peers and they sign operations based on their view of the state, both parties will only sign operations they agree on and don’t need to trust the other peer.

Opening a state channel incurs normal on-chain latency, but after the state channel has been established, operations can be executed as fast as both peers can process them, which is a major improvement over on-chain interactions.

Using state channels requires at least two on-chain transactions, one for opening and one for closing them. Once a state channel is established, no further on-chain transactions are needed unless a peer wants to withdraw or deposit funds. Even in the case of one-off transactions, it is still worth it to open a channel if there are already other channels — and gains could be acquired by relaying messages.

So, what can one do with a State Channel?

Well, there are use cases aplenty. For example, using it as payment for on-demand services like Pay-Per-View or Pay-Per-Read. Also, there is ample room for utilizing State Channels in big industries, such as gambling.

State Channels are now live as a demo! It is highly recommended to fork it and start building your own games based on æternity State Channels!

Comments

No Comments.