Ludovic Frank - Freelance developer

Lighting network, Bitcoin's fast payment system

ionicons-v5-k Ludovic Frank Feb 28, 2022
90 reads Level: Confirmed beginner

Hello ?,
This week we meet again for an article talking about the cryosphere. I'd rather say in advance that this article won't be super-specialized from a technical point of view, its aim is to introduce you to the technology, and for those who wish to go further, I'll let you sand down your favorite search engine?

If you like, you can take a look at my article on blockchain and Bitcoin, which I wrote a few months ago.

Bitcoin, a store of value

Today in the world of finance, Bitcoin is seen as a store of value; if you look at a 10-year Bitcoin curve, someone who has put their money into it for at least 3 years hasn't lost any money.
That's why it's starting to be seen as such, but being seen as a store of value doesn't make Bitcoin a good means of payment...

Transaction fees can be high.

In fact, on Bitcoin, transaction fees don't depend on the amount of the transaction, but they do vary (I could go into detail here, but that's not the point of this article).
Fees can vary from $5 to $50.
$50 for a transaction of thousands or even millions of dollars is not a problem. But imagine paying $3 for your morning coffee and then paying just $5 in transaction fees... it's not an option.

Transaction times vary and can take up to an hour.

In my experience, the Bitcoin payments received by certain projects I've worked with, on average the transaction is completely validated in 40 minutes (this is an average, sometimes it's less, sometimes it's more).
If we take the coffee example below, can you imagine having to wait 40 minutes before leaving the point of sale for your morning coffee? Again, impossible.

The crypto triangle is the "source of these inconveniences".

As you may already know, every blockchain project has to adjust a slider between three choices namely:

  • Decentralization
  • scalability
  • Security

Bitcoin's primary objective is to be incensurable and uncontrollable, and to achieve this, the emphasis has been placed on decentralization and security...

Yes, it's been around for 12 years now, and there have been hacks.

This was the case in August 2010 when 184 billion Bitcoins were generated, via a bug.
This bug was corrected by Satoshi himself, and the blockchain is distributed on a version without the fraudulent transactions at the time, phew, that didn't go far...

In spite of this episode, I was saying that it's been there for 12 years, that every day there are attempts to hack the network and yet... it's still there.

But all this comes at a cost: scalability. In fact, Bitcoin can only process around seven operations per second...

This explains the costs mentioned above, both in terms of time and fees.

For information: today, Visa processes around 1,700 transactions per second.

Crypto-currencies as layered systems

Like the Internet, blockchains operate in layers.
On the internet this layered system also exists (in fact in all computer networks).

One of the first layers is called the TCP/IP layer, I say one of the first layers, because it's not the first, if you want to know more about the OSI model, take a look at Wikipedia.

To see the article you're reading, your terminal connects to my servers using the HTTP protocol, which is an "overlay" of TCP/IP, in fact, here you're using HTTPS, because I'm adding a layer of security to the connection between you and me.

In the world of blockchains, it's the same thing: the scalability problems I mentioned earlier are on the first layer, i.e. Bitcoin... But what's stopping us from creating a level-two layer on top of that? With different objectives.

Lightning Network, when Bitcoin becomes a decentralized, ultra-fast means of payment

Let me put it in a nutshell: this level-two protocol exists, and it's called Lighting Network.

How does it work?
If you want to know more, its implementation is completely open source, so the more adventurous among you can go and read all about it.

Lightning network, works with nodes, servers that create routes for money to move.

For Lightning Network to work, it is necessary to create communication channels between the nodes.

When these channels are opened (and closed), transactions are carried out on the (level 1) Bitcoin blockchain.

The idea is to "block" Bitcoins on Lightning; these blocked Bitcoins provide the network with the liquidity it needs to function.

The owners of these nodes are rewarded with transaction fees, unlike the level-one network, where these fees depend on the amount of the transaction.

Are there any constraints?
In life, there are always choices to be made, and you can't "have it all". Lightning is very fast, but it does have its drawbacks:

  • Because of its design (it has to be fast!) and its youth, it's not as secure as Bitcoin.
  • It's not as transparent as Bitcoin: on the blockchain, you can see everything: who has sent money to whom, how much, etc. In fact, everything is visible to everyone. On Lightning, everything is much more obscure: as long as the communication channels are not closed, you can't see the movement of money on the main blockchain.
  • Bitcoins on Lightning don't belong to you "as much" as those on level one: in fact, to block Bitcoins on Lightning, they are blocked on a "multi-signature" address on level one (I'll leave you to find out, what is multiSIG?).
  • For a transaction to go through, all those involved (the sender, the receiver and the nodes through which the transaction passes) must be online, unlike Bitcoin, where you don't need to be connected to receive funds.
  • I'm sure there are others I can't think of at the time of writing?

Video of a transaction on Lightning

While researching the subject (I love researching...) I came across a video of Lightning in action. When you watch it, don't forget that, unlike Visa or Mastercard, it's decentralized... ?

Conclusion

This article is coming to an end. As I explained earlier, it's not intended to be a "technical bible", I just wanted to whet your appetite for more.I wanted to make you want to find out more, and also to give the less tech-savvy among you an overview of "what we're talking about when we talk about Lighting Networks".
I hope you enjoyed it?
Have a great week, and see you next week!