Researchers at the University of Illinois have discovered a vulnerability in Bitcoin’s most popular second-layer scaling protocol, the Lightning Network. Cosimo Sguanci and Anastasios Sidiropoulos published an academic paper describing a hypothetical attack based on node operator collusion. At the time of publication, they estimated that a coalition of 30 nodes could steal 750 bitcoins ($17 million).
For a basic explanation of the Lightning Network, read the introduction to Protos hbefore.
Researchers explain how a malicious group could control a number of nodes and render channels unresponsive in a so-called zombie attack.
- A zombie attack occurs when a set of nodes becomes unresponsive, locking up funds in any channel connected to those nodes.
- In order to defend against a zombie attack, Honest Nodes must shut down their channels and leave the Lightning Network. It requires high transaction fees to settle on Bitcoin’s base layer blockchain.
- The researchers called the zombie attacks a form of vandalism. This renders Lightning Network channels unusable and congests bitcoin throughput.
Zombie attacks have some elements in common with grief attacks, in which a network of digital assets is spammed with “harmful” transactions or invalid challenges.
Like bereavement attacks, zombie attacks appear to have no purpose other than to increase transaction fees and frustrate senders of legitimate transactions. They can also frustrate legitimate node owners who lose the fees they earn from processing Lightning Network transactions.
Researchers describe another Lightning Network vulnerability
The researchers also described another vector for attacking Bitcoin’s Lightning Network: a coordinated double-spend attack.
This attack would also require collusion between several dozen large nodes. This attack attempts to overload Bitcoin’s base layer blockchain by submitting a flood of fraudulent closing transactions for a large number of Lightning Network channels. If attackers paid high fees and jumped ahead in the queue, they might be able to spend bitcoin twice.
To defend against this massive double-spend attack, honest nodes should submit so-called justice transactions, disputing fraudulent channel closure requests.
This way, attackers would race against honest nodes to convince Bitcoin miners to include their fraudulent transactions before court transactions. If honest nodes couldn’t pay miners enough to include their court transactions first, the attackers would win.
Watchtowers are critically important to Lightning Network security
The double-spend attack requires a poorly maintained setup of its Lightning Network watchtower. Watchtowers record the state of the publicly visible Lightning network at all times. Watchtowers are designed to store data that is used in court transactions to prove that someone lied or signed a fraudulent channel closure request.
The Lightning Network Daemon (LND) includes an option private selfless watchtower that users can configure manually. These watchtowers will return the victim’s funds without taking an additional cut ⏤ on top of transaction fees ⏤ if they detect a possible attack. A Lightning Network development team is also working on reward watchtowers who will collect additional fees to perform even more tasks.
The researchers modeled the effectiveness of a massive exit attack by graphically representing historical congestion on the Bitcoin network. They speculated that a massive exit attack during a peak in congestion that began on December 7, 2017 would have had devastating effects on its victims.
Read more: Explained: Why Hackers Keep Exploiting Cross-Blockchain Bridges
Researchers flag issues and encourage better security practices
In conclusion, researchers believe that the two Lightning Network vulnerabilities are not resolved today. In terms of priority, a massive double-spend attack is more likely to be profitable than a zombie attack.
The research paper warned that the severity of a massive double-spend attack would increase as the Lightning Network matures. Victims would lose more funds, chains would experience longer delays, and the reputation of the protocol would be at risk.
Researchers have suggested defenses like increasing to_safe_delay variable in watchtower setups, which adds additional fees for waiting longer if a user decides to close a channel without any response from their counterparty.
The researchers also recommended reconfiguring watchtowers to monitor Bitcoin’s mempool for conflicting transactions.
The paper suggested a more detailed study of the two types of massive exit attacks. To their credit, researchers at the University of Illinois have indeed found a previously undetected vulnerability in Bitcoin’s Lightning Network. Their research will help improve the open source protocol, thousands of node operators and millions of users.
For more informed news, follow us on Twitter and Google News or listen to our investigative podcast Innovated: Blockchain City.